7 May 2023
At the start of this year, I set out to teach myself the Rust programming language. In Learning Rust I wrote about the unusual method I’d come up with to do that: for each language feature I learned, I would write a post on this blog. After four months and twenty-six articles, I’m going to conclude it here -- I think I’ve learned the basics, and at the moment I don’t have a good reason to learn all the details of Rust.
So, did the bizarre learning-by-writing method actually work? As a sort of final project, I’ve implemented a simple raytracer in Rust following the book Computer Graphics from Scratch by Gabriel Gambetta. That was a challenging project, but what I struggled with was the math and geometry involved, not my Rust skills. I’ll count that as a success.
A couple weeks ago, YouTube’s recommendations suggested this video to me: Learning Rust the wrong way by Ólafur Waage. In part it’s about how he learned Rust, but mostly it’s about learning and what researchers have found out about the best way to go about learning a new skill. I think it sheds some light on why the learning-by-writing method might actually make sense.
One finding from the research is that it’s best to mix different forms of learning. Writing about Rust forced me to do that: for each post, I ended up switching repeatedly between reading about the topic, writing about it, and building little Rust programs to verify my understanding and to check the example code that I wanted to include in the article. Going back and forth like that can feel like a poor use of one’s time, but the research indicates that it’s more effective than focusing on one activity. Apparently this is called “interleaving”.
Another concept I wouldn’t have thought of before is called “generation”, which means that the learner generates questions about the topic and then tries to answer them. I actually did exactly that for each article, but without realizing it was a technique -- I just wanted some idea of what I was going to write about, so I always started by writing down some questions that the completed article would hopefully answer.
I came up with the idea of learning-by-writing because other things I tried didn’t work for me but looking back, and with the insights from Ólafur’s presentation, I think it makes a lot of sense. Will I use it again the next time I want to learn a new skill? Perhaps -- my feeling is it’s useful if the skill I’m trying to learn is actually difficult. If not, I’d still go with the old “jump right in and learn by doing” method.