I’d been putting it off for over a year — though the idea of the language intrigued me (and my friend would not stop nagging me about learning it), something in me was hesitant on starting to learn Rust:
How would I do it? How do I even learn a language like that? I had no idea how to get started on this.
These kinds of questions swarmed my head every time I thought about starting to ‘learn’ Rust. This story is a guide for people like me who:
And, very crucially:
As I implied earlier, I had a friend who had been pushing me to learn Rust for almost a year, so, I thought to start with his recommendation — “The Book”. The Book is a nickname for the authoritative tutorial on learning Rust, it consists of 21 chapters, each focusing on a core part of the Rust language, and is available on the Rust-Lang website.
My initial approach was to simply go through, chapter-by-chapter, and learn about the language, but that quickly went awry for a number of reasons:
There were some fundamental things to change regarding my initial mindset:
Finally, I had to accept that as part of the learning process, I would make mistakes, miss out on some concepts, and/or learn the wrong things, at least initially. Instead of agonising over that, however, I could focus on improving myself and correcting those mistakes, rather than trying to be perfect on the first try.
With some help from others and internal reflection, I’ve developed a guide to help others who are similarly stuck:
Chapters 1,2, 3, and 4 should be enough for this, though if you’re struggling by chapter 4, you can leave it halfway. We’ll cover it later. Simply follow along with the instructions and try out some code examples until you have an idea of how things work. Make sure to space it out, though.
I’ve never been good at coming up with project ideas on my own, so this wasn’t the easiest for me. If you’re like me, here’s the way I tackled this hurdle (I’ll demonstrate at the end):
I am not the biggest fan of basic CRUD-y apps, so I would re-prompt for a different result. Here’s the version I used when I was learning:
Here’s the fun part: take one feature from the ‘v1’ of your language and try to come up with a simple way to implement it. It’s okay to be puzzled or confused, here’s what you can do:
cargo run -- 'query'
If you really hit a hard wall, you can take a go at asking a tool like Claude for some ‘pointers’. I need to stress that you only ask for general pointers/guides — AI tools can be very wrong on low-level code. In addition, much of the learning process is negated if you simply get all the code spoon-fed to you. You can, however, ask for some explanations of concepts when the documentation/source is being excessively complex.
At the end of the day, explore how to build simplified versions of things. Be sure to listen when your instincts prompt you to explore certain things, as long as it’s not too time-consuming.
As an example, when trying to understand how to extract queries like ‘key.value[0]’, I explored how Regex engines work and built a simple parser in JavaScript to parse strings (YouTube videos were particularly helpful for this) into ASTs. But, I left as soon as the course got into building a full-fledged virtual machine, as I felt that would be too much of a diversion. I could always come back to it later.
Repeat this for the next couple of sub-features, and you’ll find yourself gaining a deeper understanding of how the language works, as well as building something reasonable.
It’s been somewhat fun to build this, and I have learned some things about Rust. My next intent is probably to build something more complex, which forces me to cover even more of the language.
After that, it’s off to Rust In Action, a project-based book on systems programming in Rust.
Anyway, this is all from a newer Rust developer’s perspective. Let me know if this helped your learning journey.