floatings
This commit is contained in:
parent
9d23dc5e83
commit
04b6a18013
7
variables/Cargo.lock
generated
Normal file
7
variables/Cargo.lock
generated
Normal file
@ -0,0 +1,7 @@
|
||||
# This file is automatically @generated by Cargo.
|
||||
# It is not intended for manual editing.
|
||||
version = 3
|
||||
|
||||
[[package]]
|
||||
name = "variables"
|
||||
version = "0.1.0"
|
8
variables/Cargo.toml
Normal file
8
variables/Cargo.toml
Normal file
@ -0,0 +1,8 @@
|
||||
[package]
|
||||
name = "variables"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[dependencies]
|
17
variables/src/main.rs
Normal file
17
variables/src/main.rs
Normal file
@ -0,0 +1,17 @@
|
||||
fn main() {
|
||||
let x = 5;
|
||||
let x = x + 1;
|
||||
|
||||
println!("X: {x}");
|
||||
{
|
||||
let x = x * 2;
|
||||
println!("x: {x}");
|
||||
}
|
||||
println!("x: {x}");
|
||||
|
||||
let fx = 2.0;
|
||||
let fy : f32 = 3.0;
|
||||
println!("fx: {fx}");
|
||||
println!("fy: {fy}");
|
||||
|
||||
}
|
Loading…
Reference in New Issue
Block a user