This commit is contained in:
stephan.klauberg 2023-10-07 06:51:25 +02:00
parent 2bacd04fb1
commit 2fdd38e94e
2 changed files with 3 additions and 3 deletions

View File

@ -5,11 +5,11 @@
// Execute `rustlings hint primitive_types5` or use the `hint` watch subcommand
// for a hint.
// I AM NOT DONE
// I AM DONE
fn main() {
let cat = ("Furry McFurson", 3.5);
let /* your pattern here */ = cat;
let (name,age) = cat;
println!("{} is {} years old.", name, age);
}

View File

@ -12,7 +12,7 @@
fn indexing_tuple() {
let numbers = (1, 2, 3);
// Replace below ??? with the tuple indexing syntax.
let second = ???;
let second = numbers.1;
assert_eq!(2, second,
"This is not the 2nd number in the tuple!")