Why learn Rust?
-
Memory safety without a garbage collector.
-
C-level performance, modern ergonomics.
-
Powering the next generation of tools (ripgrep, Astro's Rolldown, Bun internals).
-
A standout on resumes for systems and infra roles.
What you can build with Rust
Performance-critical backends Systems and embedded programming WebAssembly modules CLI tools and compilers
Rust tutorials
53 articles · page 1 of 3Hand-written tutorials, ordered as a recommended learning path.
- 01 What Is Rust? A practical introduction to Rust — where it came from, the three design goals that shape every decision, what it's the right tool for, and what it isn't. With your first Rust program.
- 02 Install & First Program A complete walkthrough of installing Rust with rustup on macOS, Linux, and Windows, then creating your first Cargo project and running it from the terminal.
- 03 Variables & Types A practical tour of Rust variables and scalar types — let, mut, shadowing, integers, floats, booleans, chars, tuples, arrays, type inference, and constants. With runnable examples.
- 04 Functions A practical guide to Rust functions — fn syntax, parameter types, return values, the difference between statements and expressions, the trailing-expression rule, and early returns.
- 05 Ownership Basics A friendly tour of Rust's ownership system — the three rules, move semantics, Copy vs Clone, borrowing with & and &mut, the borrow checker, and the beginner errors you'll see first.
- 06 Async with Tokio Learn async Rust with Tokio from scratch. Covers async/await syntax, spawning tasks, channels, TCP servers, and common pitfalls with working examples.
- 07 Concurrency Patterns Learn Rust concurrency with channels, Mutex, Arc, and thread-safe patterns. Covers mpsc, shared state, thread pools, and real-world examples.
- 08 anyhow & thiserror Master Rust error handling with anyhow for applications and thiserror for libraries. Practical patterns, conversions, and context-rich error reporting.
- 09 Iterators & Closures Master Rust iterators and closures for functional-style programming. Covers map, filter, fold, chaining, custom iterators, and Fn trait family.
- 10 Lifetimes Simply Learn Rust lifetimes from scratch with clear visual examples, common patterns, and practical rules that make lifetime annotations easy to understand.
- 11 macro_rules! Learn to write Rust declarative macros with macro_rules!. Covers syntax, fragment specifiers, repetitions, hygiene, and practical macro patterns.
- 12 Advanced Patterns Go beyond basic match with pattern guards, bindings, nested patterns, or-patterns, and real-world refactoring strategies in Rust.
- 13 Smart Pointers Guide A hands-on guide to Rust smart pointers covering heap allocation with Box, shared ownership with Rc, and thread-safe sharing with Arc.
- 14 Trait Objects vs Generics Understand the trade-offs between dynamic dispatch with trait objects and static dispatch with generics in Rust through real-world examples.
- 15 Tokio vs async-std A practical comparison of Tokio and async-std covering performance, ecosystem, API design, and migration considerations for async Rust projects.
- 16 Async Runtime Internals Explore how Rust async runtimes work internally, including futures, wakers, executors, and the reactor pattern that powers async I/O.
- 17 Closures & Fn Traits Master Rust closures, understand Fn, FnMut, and FnOnce traits, learn how closures capture variables, and use closures effectively in your code.
- 18 thiserror & anyhow Learn practical Rust error handling using thiserror for library errors and anyhow for application errors, with real-world patterns and examples.
- 19 Cell & RefCell Understand Rust's interior mutability pattern using Cell and RefCell, when to use each, and how they let you mutate data behind shared references.
- 20 macro_rules! Guide Master Rust's macro_rules! with practical examples covering syntax matching, repetition, common patterns, and debugging tips for declarative macros.