]> git.lizzy.rs Git - rust.git/blob - compiler/rustc_error_codes/src/error_codes/E0601.md
Rollup merge of #93556 - dtolnay:trailingcomma, r=cjgillot
[rust.git] / compiler / rustc_error_codes / src / error_codes / E0601.md
1 No `main` function was found in a binary crate.
2
3 To fix this error, add a `main` function:
4
5 ```
6 fn main() {
7     // Your program will start here.
8     println!("Hello world!");
9 }
10 ```
11
12 If you don't know the basics of Rust, you can look at the
13 [Rust Book][rust-book] to get started.
14
15 [rust-book]: https://doc.rust-lang.org/book/