Part 0: Rust in One Hour
Who this part is for
You will walk away with
- Every concept a working Rust program uses day to day
- A real mental model of ownership & borrowing
- A small CLI program you wrote and ran yourself
Reading time
Why this part exists
Most Rust books start with syntax. Syntax is the least interesting thing about Rust. The interesting thing is the idea — the one rule the compiler enforces about who is allowed to touch what, and when.
Part 0 teaches that idea in plain English, with pictures, before you meet a single semicolon you have to take seriously. Eight short chapters. A reader who goes no further can still write small useful Rust programs. A reader who goes further has a foundation the rest of the book can build on without rushing.
The eight stops
- Why you will actually like Rust
- Hello, Rust — install, compile, run in five minutes
- Values, names, and the "let" word
- The shape of data — structs, enums, and tuples in pictures
- Ownership in one page
- Borrowing in one page
- Option and Result — Rust's answer to "what if it failed?"
- Your first CLI — put it all together in a real program
Then: Where to next.
How to read Part 0
Read it in order, top to bottom. Each chapter is short on purpose. Every code block has a “Run in Playground” link — click it, let the code run in your browser, then come back. You will not absorb Rust by reading alone. You will absorb it by running six-line programs and watching what happens.
When you finish Part 0, choose your next stop from Where to next.
A small promise
We will never use the phrases “it’s simple” or “it’s easy” in this book. If something is hard, we will say it is hard, and we will stand next to you until it is not hard anymore. The promise is not that Rust is easy. The promise is that the way we teach it here is the gentlest path up the mountain you will find on the internet.
Let’s begin.