Skip to content

Latest commit

 

History

History

datatypes

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

Basic DataTypes:

  • main.rs

  • names

fn main() {
    /* declaring name */
    let name = "User One";

    /* printing it out */
    println!("name: {}", name);
}
  • numbers (int)
fn main() {
    /* for storing or declaring int use u32 */
    let age:u32 = 20; 

    /* printing the data that we stored */
    println!("age: {} ", age);
}
$ cargo run