https://github.com/p810/rust-exercises
A collection of exercises that I'm doing alongside Rust's book
https://github.com/p810/rust-exercises
Last synced: about 2 months ago
JSON representation
A collection of exercises that I'm doing alongside Rust's book
- Host: GitHub
- URL: https://github.com/p810/rust-exercises
- Owner: p810
- Created: 2020-10-26T23:33:40.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-11-02T23:25:36.000Z (over 5 years ago)
- Last Synced: 2026-01-02T06:13:44.189Z (6 months ago)
- Language: Rust
- Size: 788 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# rust-exercises
A collection of exercises that I'm doing alongside Rust's official book, [The Rust Programming Language](https://doc.rust-lang.org/book/title-page.html).
## Table of Contents
| Directory | Chapter | Purpose |
|-----------|---------|---------|
| [`branches/`](branches/) | [3.5 Control Flow](https://doc.rust-lang.org/book/ch03-05-control-flow.html) | Playing around with control structure syntax |
| [`enums/`](enums/) | [6 Enums and Pattern Matching](https://doc.rust-lang.org/book/ch06-00-enums.html) | Explores enums, `match`, and `if let` |
| [`functions/`](functions/) | [3.3 Functions](https://doc.rust-lang.org/book/ch03-03-how-functions-work.html) | Shows how Rust handles implicitly returned values |
| [`hello_cargo/`](hello_cargo/) | [1.3 Hello, Cargo!](https://doc.rust-lang.org/book/ch01-03-hello-cargo.html) | A mixture of chapters 1.3 and 2, where I tried my hand at a range of functionality (like enums, `Option`, etc.) and got acquainted with `cargo`. Doesn't work because I decided to wait until I got further into the book to work with some of these concepts. |
| [`hello_world/`](hello_world/) | [1.2 Hello, World!](https://doc.rust-lang.org/book/ch01-02-hello-world.html) | A simple hello world app |
| [`stack_and_heap/`](stack_and_heap/) | [4 Understanding Ownership](https://doc.rust-lang.org/book/ch04-00-understanding-ownership.html) | Explores concepts relating to memory management: Ownership, references, moving pointers between variables, cloning data, and the difference between the stack and heap |
| [`structs/`](structs/) | [5 Using Structs to Structure Related Data](https://doc.rust-lang.org/book/ch05-00-structs.html) | Introduces structs, `impl` and methods, associated functions, etc. |
| [`types_and_structures/`](types_and_structures/) | [3.5 Control Flow](https://doc.rust-lang.org/book/ch03-05-control-flow.html) | Demonstrates tuples, arrays, and loops |
| [`variables/`](variables/) | [3.1 Variables and Mutability](https://doc.rust-lang.org/book/ch03-01-variables-and-mutability.html) | A brief introduction to variable assignment and mutability in Rust |
| [`library/`](library/) | [7 Managing Growing Projects with Packages, Crates, and Modules](https://doc.rust-lang.org/book/ch07-00-managing-growing-projects-with-packages-crates-and-modules.html) | Goes over some of the semantics around how code is organized in Rust, scope resolution, etc. |
| [`collections/`](collections/) | [8 Common Collections](https://doc.rust-lang.org/book/ch08-00-common-collections.html) | Introduces some of Rust's compound data structures, collections, which can be used to store multiple values on the heap |