Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
with
13 additions
and
0 deletions.
-
+13
−0
src/main.rs
|
@@ -85,7 +85,20 @@ fn m_atch() { |
|
|
_foo = 99; |
|
|
} |
|
|
|
|
|
fn o_ption() { |
|
|
let mut rng = 0..7; |
|
|
println!("> {:?}", rng.next()); |
|
|
println!("> {:?}", rng.next()); |
|
|
loop { |
|
|
match rng.next() { |
|
|
Some(n) => println!("{:?}", n), |
|
|
None => {println!("broke"); break}, |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
fn main() { |
|
|
o_ption(); |
|
|
get_element_n_of_string(); |
|
|
misreuse_of_closure(); |
|
|
bytes_to_utf8(); |
|
|
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session.
You signed out in another tab or window. Reload to refresh your session.