How this Rust track works
- rustc in the playground — write a single file with
fn main()andprintln!; the dev runner compiles withrustcand runs the binary. No Cargo in simple lessons. - Ownership is the core lesson — the compiler enforces memory safety at compile time. Borrow checker errors are normal while learning—read the message, fix one issue, re-run.
- Prerequisites — finish JavaScript (functions, objects) and ideally Java or C++ for typed-systems context. Rust is not usually a first language.
Multi-crate Cargo projects, async runtimes, and WebAssembly builds run locally—lessons simulate patterns with println! where the sandbox is single-file.
Install on your device (macOS, Linux, Windows)
Install Rust via rustup for local cargo projects; playground compiles with rustc.
macOS
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | shthen restart terminal.- Or
brew install rustup-init && rustup-init
Linux
- Same rustup script:
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh - Debian may need:
sudo apt install -y build-essential curlfirst.
Windows
- Download
rustup-init.exefrom rustup.rs and run it (Visual Studio C++ build tools may be required).
Verify: rustc --version and cargo --version.
Run code on this site (Backend & language playgrounds)
- Clone or open this project locally; copy
.env.exampleto.env. - Ensure
LEARNING_RUNNER_ENABLED=trueandLEARNING_RUNNER_URL=http://127.0.0.1:9999/v1/execute. - Terminal 1:
php artisan serve(orcomposer run devfor Laravel + Vite + runner together). - Terminal 2:
npm run runner— keep it running while you click Run on server.
Rust is a systems programming language focused on memory safety without a garbage collector. It compiles to native machine code, runs without a runtime VM, and catches many bugs at compile time through ownership and types.
How this track differs from JavaScript and Java
After the JavaScript track, you know dynamic typing and garbage collection. After Java, you know static types and a JVM. Rust is statically typed like Java but has no GC—the compiler tracks who owns each value and when memory is freed.
Unlike scripting in the browser, Rust targets CLIs, servers, embedded systems, and WebAssembly. Expect the borrow checker to feel strict at first—that is the language teaching safe memory use.
What you will learn
- Syntax: variables, types, control flow, functions, structs, enums, pattern matching
- Ownership, borrowing, references, slices, and lifetimes basics
- Collections,
Result/Option, error handling, iterators - Traits, generics, modules, testing, concurrency intro, and Cargo workflow
- Interview essentials, production habits, and a WebAssembly teaser
Playground setup
This topic uses the server_compiled profile: your code compiles with rustc as a single main.rs file. Use fn main() and println! for output. Cargo multi-file projects are taught for local development.
Self-check
- In one sentence, what makes Rust different from Java regarding memory?
- Why do we recommend prior programming experience before Rust?
Interview prep
- What is Rust in one sentence?
A statically typed systems language that compiles to native code and enforces memory safety through ownership and borrowing—without a garbage collector.