rustlings/exercises/enums/enums1.rs
Xander b09049b906 feat: Added exercises/enums
Added 3 new exercises for enums, enums{1-3}.rs
2019-08-25 11:29:10 -04:00

46 lines
440 B
Rust

// enums1.rs
// Make me compile by adding my favorite fruit in the enum definition :)
// Hints can be found below
#[derive(Debug)]
enum Fruit {
Banana,
Apple,
Pear,
// Add another fruit here
}
fn main() {
println!("The writer likes like {:#?}", Fruit::Mango);
}
// Look at the syntax of how the fruit is being printed to figure out what to
// add to the enum. (HINT: I really like Mangos)