Delving deep into advanced Rust concepts
Now that we have built upon our foundational knowledge of Rust, it’s time to expand our bases with some more concepts that will make us even more comfortable with Rust and let us build real-world projects with it.
In the following subsections, we will learn about concepts that unlock some advanced functionality for us, such as hashmaps, ownership, borrowing, crates, modules, and cargo. These help us work smoothly with slightly bigger projects. However, you may end up using these features more often than you expect, so it’s important to pay close attention to these subsections.
Hashmaps
Hashmaps in Rust, as in many other programming languages, are collections of key-value pairs. They are especially efficient for scenarios where you need to quickly look up data using keys rather than index values. The efficiency of hashmaps comes from their use of a hashing function, which converts keys into hash codes. These hash codes...