The course
Rust lessons
Follow the 11 lessons in order or jump to the topic you want to practice.
Hello, Rust
Follow your first program from the main function to the terminal.
Open lessonVariables and types
Name values, discover their types, and update a mutable variable.
Open lessonDecisions and loops
Watch a loop repeat and an if expression choose which code runs.
Open lessonFunctions
Pass an argument into a function and trace the value it returns.
Open lessonOwnership
Follow a String as ownership moves from one binding to another.
Open lessonBorrowing
Read through a shared reference and update through a mutable reference.
Open lessonVectors and indexing
Build a growable list and check whether an item exists.
Open lessonStructs
Group related values into one type with named fields.
Open lessonEnums and match
Model different states and handle each one with a match arm.
Open lessonRecoverable errors
Follow a parse error through a function and handle it with Result.
Open lessonIterators
Transform a sequence, keep the values you need, and collect them.
Open lesson