mirror of
https://github.com/rust-lang/rustlings.git
synced 2026-01-11 13:19:18 +00:00
13 lines
477 B
Rust
13 lines
477 B
Rust
// variables5.rs
|
|
// Execute `rustlings hint variables5` or use the `hint` watch subcommand for a hint.
|
|
|
|
fn main() {
|
|
let number = "T-H-R-E-E"; // don't change this line
|
|
let name = "Otto".to_string(); // Also workd for var that live in memory
|
|
println!("Spell a Number : {}", number);
|
|
println!("Number plus two is : {}", name);
|
|
let number = 3; // don't rename this variable
|
|
let name = "Lucas".to_string();
|
|
println!("Number plus two is : {}", name);
|
|
}
|