-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add rustfinity constant and primitive data solutions
- Loading branch information
1 parent
fab81b8
commit bb4e324
Showing
2 changed files
with
19 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
// Define a constant MAX_SIZE with a value of 100. | ||
// NOTE: Define the constant outside the main function | ||
// Your code here | ||
|
||
pub fn main() -> i32 { | ||
MAX_SIZE | ||
} | ||
|
||
const MAX_SIZE : i32 = 100; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
pub fn data_types() { | ||
// 1. Define variable `x` of type `u8` | ||
let x : u8; | ||
// 2. Define variable `y` of type `f64` | ||
let y : f64; | ||
// 3. Define variable `z` of type `bool` | ||
let z : bool; | ||
// 4. Define variable `a` of type `char` | ||
let a : char; | ||
} |