Learning Rust sm h
This commit is contained in:
12
src/main.rs
12
src/main.rs
@@ -1,6 +1,16 @@
|
||||
use std::io;
|
||||
use rand::Rng;
|
||||
|
||||
fn main()
|
||||
{
|
||||
println!("Hello, world!");
|
||||
// let mut x = String::new();
|
||||
|
||||
// io::stdin().read_line(&mut x)
|
||||
// .expect("Failed to read line");
|
||||
|
||||
let x = rand::thread_rng().gen_range(1, 101);
|
||||
|
||||
println!("{}", x);
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user