Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- fn main() {
- 'outer: for x in 0..10 {
- 'inner: for y in 0..10 {
- if x % 2 == 0 { continue 'outer; } // continues the loop over x
- if y % 2 == 0 { continue 'inner; } // continues the loop over y
- println!("x: {}, y: {}", x, y);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement