Writing unit tests while coding forces us to keep APIs usable, keeps the code testable, and prevents many other issues.
Much has been written about the benefits of unit testing.
However, I’ve never heard about the analogy between unit testing and spaced repetition.
Just like unit testing enforces code standards, so does writing spaced repetition questions while we learn force us to understand the material better.
You cannot write a question-and-answer pair about something you don’t grasp. Especially a simple question that has a single unique answer.
It’s easy, too.
Just highlight as you read, pick out the most important highlights, and write clear and straightforward questions to yourself about those.
At the very least you’ll learn the material better. And if you also do spaced repetition on the questions, you’ll never forget the material.