initial commit
This commit is contained in:
@@ -0,0 +1 @@
|
||||
/target
|
||||
Generated
+7
@@ -0,0 +1,7 @@
|
||||
# This file is automatically @generated by Cargo.
|
||||
# It is not intended for manual editing.
|
||||
version = 4
|
||||
|
||||
[[package]]
|
||||
name = "thebook"
|
||||
version = "0.1.0"
|
||||
@@ -0,0 +1,6 @@
|
||||
[package]
|
||||
name = "thebook"
|
||||
version = "0.1.0"
|
||||
edition = "2024"
|
||||
|
||||
[dependencies]
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
fn main() {
|
||||
let x = 5;
|
||||
let number = 8;
|
||||
let mut y = 5;
|
||||
println!("Hello, world!");
|
||||
println!("X: {}", x);
|
||||
|
||||
println!("Y: {}", y);
|
||||
|
||||
y = 12;
|
||||
println!("Y has been set to: {}", y);
|
||||
|
||||
if y < 11 {
|
||||
println!("Y is less than 11: Y is {}", y);
|
||||
} else {
|
||||
println!("Y is more than 11: Y is {}", y);
|
||||
}
|
||||
|
||||
y = 6;
|
||||
println!("Y has been set to: {}", y);
|
||||
if y < 11 {
|
||||
println!("Y is less than 11, Y is {}", y);
|
||||
}
|
||||
|
||||
if number % 4 == 0 {
|
||||
println!("Y is divisible by 4");
|
||||
} else if number % 3 == 0 {
|
||||
println!("Y is divisible by 3");
|
||||
} else if number % 2 == 0 {
|
||||
println!("Y is divisible by 3");
|
||||
}
|
||||
println!("Y has been changed to: {}", y);
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user