rust jump back to an outer loop code example
Example: rust jump back to an outer loop
'outer: for v in m {
'inner: for i in v {
if i < 0 {
println!("Found {} {}", i, v);
break 'outer;
}
}
}
// Consider refactoring the nested loop into a function and use return to break out.