- fn
- main
Rust main function
- There are two types of crates: libraries and executables. The latter can also contain libraries.
- For executable crates we must have a file called src/main.rs and it must have a function called main.
- This is the most basic definition of a main function. It does nothing.
examples/functions/main/src/main.rs
fn main() {}