- fn
- main
- println
Hello World
- Rust files must have an extension of .rs.
- The main Rust file must have a function called main.
- println! is a macro (it looks like function, it generates some Rust code during compilation).
examples/intro/hello/src/main.rs
fn main() { println!("Hello World!") }
rustc src/main.rs
./main