mirror of
https://github.com/rust-lang/rustlings.git
synced 2026-01-03 09:19:18 +00:00
Pending changes exported from your codespace
This commit is contained in:
parent
1b07cf56e4
commit
99b032cb81
@ -13,7 +13,6 @@
|
|||||||
// Execute `rustlings hint intro1` or use the `hint` watch subcommand for a
|
// Execute `rustlings hint intro1` or use the `hint` watch subcommand for a
|
||||||
// hint.
|
// hint.
|
||||||
|
|
||||||
// I AM NOT DONE
|
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
println!("Hello and");
|
println!("Hello and");
|
||||||
|
|||||||
@ -5,8 +5,8 @@
|
|||||||
// Execute `rustlings hint intro2` or use the `hint` watch subcommand for a
|
// Execute `rustlings hint intro2` or use the `hint` watch subcommand for a
|
||||||
// hint.
|
// hint.
|
||||||
|
|
||||||
// I AM NOT DONE
|
// I AM DONE
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
printline!("Hello there!")
|
println!("Hello World!")
|
||||||
}
|
}
|
||||||
|
|||||||
@ -5,9 +5,9 @@
|
|||||||
// Execute `rustlings hint variables1` or use the `hint` watch subcommand for a
|
// Execute `rustlings hint variables1` or use the `hint` watch subcommand for a
|
||||||
// hint.
|
// hint.
|
||||||
|
|
||||||
// I AM NOT DONE
|
// I AM DONE
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
x = 5;
|
let x = 5;
|
||||||
println!("x has the value {}", x);
|
println!("x has the value {}", x);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -3,10 +3,10 @@
|
|||||||
// Execute `rustlings hint variables2` or use the `hint` watch subcommand for a
|
// Execute `rustlings hint variables2` or use the `hint` watch subcommand for a
|
||||||
// hint.
|
// hint.
|
||||||
|
|
||||||
// I AM NOT DONE
|
// I AM DONE
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
let x;
|
let x: i32 = 0;
|
||||||
if x == 10 {
|
if x == 10 {
|
||||||
println!("x is ten!");
|
println!("x is ten!");
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@ -3,9 +3,9 @@
|
|||||||
// Execute `rustlings hint variables3` or use the `hint` watch subcommand for a
|
// Execute `rustlings hint variables3` or use the `hint` watch subcommand for a
|
||||||
// hint.
|
// hint.
|
||||||
|
|
||||||
// I AM NOT DONE
|
// I AM DONE
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
let x: i32;
|
let x: i32 = 90;
|
||||||
println!("Number {}", x);
|
println!("Number {}", x);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -3,10 +3,10 @@
|
|||||||
// Execute `rustlings hint variables4` or use the `hint` watch subcommand for a
|
// Execute `rustlings hint variables4` or use the `hint` watch subcommand for a
|
||||||
// hint.
|
// hint.
|
||||||
|
|
||||||
// I AM NOT DONE
|
// I AM DONE
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
let x = 3;
|
let mut x: i32 = 3;
|
||||||
println!("Number {}", x);
|
println!("Number {}", x);
|
||||||
x = 5; // don't change this line
|
x = 5; // don't change this line
|
||||||
println!("Number {}", x);
|
println!("Number {}", x);
|
||||||
|
|||||||
@ -8,6 +8,6 @@
|
|||||||
fn main() {
|
fn main() {
|
||||||
let number = "T-H-R-E-E"; // don't change this line
|
let number = "T-H-R-E-E"; // don't change this line
|
||||||
println!("Spell a Number : {}", number);
|
println!("Spell a Number : {}", number);
|
||||||
number = 3; // don't rename this variable
|
let number = 3; // don't rename this variable
|
||||||
println!("Number plus two is : {}", number + 2);
|
println!("Number plus two is : {}", number + 2);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user