mirror of
https://github.com/notohh/rustlings.git
synced 2024-11-25 23:04:17 -05:00
Update option1.rs
This commit is contained in:
parent
135e5d47a7
commit
6d3a412d47
1 changed files with 2 additions and 2 deletions
|
@ -5,7 +5,7 @@
|
||||||
|
|
||||||
//you can modify anything EXCEPT for this function's sig
|
//you can modify anything EXCEPT for this function's sig
|
||||||
fn print_number(maybe_number: Option<u16>) {
|
fn print_number(maybe_number: Option<u16>) {
|
||||||
println!("printing: {}", *maybe_number);
|
println!("printing: {}", maybe_number.unwrap());
|
||||||
}
|
}
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
|
@ -20,4 +20,4 @@ fn main() {
|
||||||
|
|
||||||
numbers[iter] = number_to_add;
|
numbers[iter] = number_to_add;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue