All lessons

Your First Program

6 min · Rust

Write and run your very first Rust program — right here on the page.

Rust · Your First Program0/5 cleared

Enemy 1 of 5

A Rust program starts in fn main. println! prints a message — note the exclamation mark, which marks it as a macro.

The text goes inside the parentheses and quotes. Press Run.

You
Pincer Crab

Loading editor...

Ln 1, Col 1Spaces: 4
Sign up to fightTarget output: Hello, World!