FAQ
What is trprt.io?
It's a website consisting of exercises designed to improve your ability to read code quickly, which ultimately will help you write it quickly and correctly as well.
Why did you make this site?
I've tutored programming professionally with students of all ages. Over the years I've found that the number one reason that beginners get frustrated when writing code is surprisingly that they're not able to read what they've written.
Unlike other sites and courses, the focus of trprt is on developing your ability to read code just as much as your ability to write it, which makes all other aspects of programming easier.
Why should I practice reading code?
A beginner writes a program, then runs it. It doesn't do what they expected. They re-read the code they wrote, but they still don't know why it didn't do what they expected. They're stuck.
An expert writes a program, then runs it. It doesn't do what they expected. They re-read the code they wrote, spot which part of the code is causing the misbehavior, and fix it.
Why did the beginner get stuck while the expert did not? In both cases, the first draft of the program had a bug. The beginner got stuck in the reading phase, not the writing phase. The difference is that the beginner was not able to read their own code. If they knew how to read code, they'd know why their program didn't do what they wanted.
How should I use this site?
Start with the control flow quiz on a difficulty level where you're able to solve most of the questions, but still find it challenging. If you're a beginner, start with just the int data type. If you encounter something you don't recognize, Google it or look it up in Think Python (I will add more guidance on trprt itself soon!).
You should sign up for a free account so that your scores will be recorded automatically. As you practice, your speed will improve and you will see a chart of your progress. Once your speed plateaus, you should move on to a different exercise or difficulty level.
Pushing yourself to improve your time along with immediate feedback on your performance is a very important component of deliberate practice, which is the key to mastery (skip to 4:25 in the video below if you're in a hurry).
Shouldn't beginners write code too?
Definitely! You shouldn't just read code. Use the reading exercises to improve your writing ability.
I'm planning to add exercises that require you to write code as well. If you have any suggestions or requests, contact me.
Aren't randomly generated programs too meaningless to be useful for learning?
Good question! You're right that real-world code will tend to have more meaningful variable names, comments, and a clearer purpose, whereas the randomly generated programs on trprt are just semi-random manipulation of data with meaningless variable names.
However, regardless of comments and variable names, you need to be able to read what your code actually does -- and this doesn't depend on the comments or variable names at all, since those don't affect how the computer runs the code. Sometimes comments and variable names can even be misleading!
This especially becomes clear when debugging: if you don't know why a bug is happening in your code, this is, almost by definition, because you're not able to correctly read what you've written. If you were able to read it correctly, you'd know why it's not doing what you want.
This is great! How can I show my appreciation?
Thanks! The biggest thing you can do to help is share trprt on social media:
You can also sign up here to hear about future updates.
Why is the site called trprt?
It's short for interpreter, which is the term for a program that executes other programs. In these exercises, you act as the interpreter.
It's also a palindrome.
How do you pronounce trprt?
"Ter-Pert." Rhymes with "Fur Shirt."
What in-browser Python interpreter does trprt use?
Skulpt!