The main source repository for the Rust programming language, containing the compiler, standard library, and documentation.
rust-lang/rustlings
Small Rust exercises that help you learn to read and write Rust code, meant to be worked through alongside the official Rust book.
- Stars
- 64,412
- Forks
- 11,258
- Open issues
- 38
- Last commit
- 23 days ago
What is it?
Rustlings is a set of small, guided exercises for learning Rust. Each exercise is a short file with a compile error, a failing test, or a logic bug that you fix by editing the code. Working through them builds familiarity with Rust syntax, the compiler's error messages, and core language concepts.
The project is designed to be used alongside the official Rust book rather than as a replacement for it. The exercises are run from a command line tool, which checks your progress and moves you to the next one once the current exercise compiles and passes.
The project's website covers setup instructions and more details about how the exercises are organized.
Key features
- 01Exercises cover Rust syntax, compiler errors, and core language concepts.
- 02A command line tool checks your solutions and advances you through the exercises.
- 03Each exercise is a small file you edit directly in your own editor.
- 04Designed to be worked through alongside the official Rust book.
Use cases
- Learning Rust for the first time while reading the official book.
- Practicing reading compiler error messages in a low-stakes setting.
- Warming up on Rust fundamentals before starting a real project.
Topics
FAQ
- What is rustlings?
- Small Rust exercises that help you learn to read and write Rust code, meant to be worked through alongside the official Rust book. Rustlings is a set of small, guided exercises for learning Rust. Each exercise is a short file with a compile error, a failing test, or a logic bug that you fix by editing the code. Working through them builds familiarity with Rust syntax, the compiler's error messages, and core language concepts.
- Is rustlings free to use? What license does it have?
- rustlings is open source under the MIT license. Check the license terms before using it in commercial products.
- Is rustlings still maintained?
- Actively maintained. The last commit to rustlings was on Sep 29, 2026.
- What can I use rustlings for?
- Learning Rust for the first time while reading the official book. Practicing reading compiler error messages in a low-stakes setting. Warming up on Rust fundamentals before starting a real project.
- Where can I get rustlings?
- The source code and installation instructions are on GitHub: https://github.com/rust-lang/rustlings
Summary generated by AI from the project's README. GitHub stats refresh daily.
Related projects
Sway is a Rust-inspired programming language for writing smart contracts on the Fuel blockchain.
A markup-based typesetting system built as a modern, easier-to-learn alternative to LaTeX, with its compiler and CLI in Rust.
Open-source, composable payments platform in Rust for routing, retrying, vaulting and reconciling payments across many processors.
A super-fast TypeScript/JavaScript compiler and parser written in Rust, usable from Rust and from JavaScript.
A collection of high-performance JavaScript and TypeScript tools written in Rust, including a parser, linter, formatter, transformer, minifier and resolver.