📜  rust 跳回外循环 - Rust 代码示例

📅  最后修改于: 2022-03-11 14:49:25.509000             🧑  作者: Mango

代码示例1
'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.