Standard Library Reference, Functions & Ready-to-Run Code Examples
Part of The Direct Path to Linux Ubuntu
— free for all students and developers.
Rust's ownership system guarantees memory safety without a GC — no null pointers, no data races, no buffer overflows at compile time.
High-level code compiles to the same machine code as hand-written C — performance without compromise.
Docker, WebAssembly, OS kernels, game engines — Rust is the modern C/C++ replacement endorsed by the Linux kernel project.
Async/await, rayon for data parallelism, Arc<Mutex<T>> — concurrency without fear of data races.
Run a Rust program:
cargo new myproject # create new Rust project cargo run # compile and run cargo build # compile only (debug) cargo build --release # optimized release build cargo test # run all tests cargo fmt # format code with rustfmt cargo clippy # run linter cargo add serde # add dependency to Cargo.toml rustc main.rs # compile single file without Cargo ./main # run compiled binary