I’ve had an interest on how people learn to program and have been thinking about the patterns I’ve seen that work. I’m particularly interested in the patterns I applied when I first started out.
I learned how to program in my junior high school’s “computer shop” class. One day we had to take a working slot machine application and alter it so that you always win. This assignment has a lot of things going for it:
- The goal is simple to understand and remember
- It’s fun
- To do it, you need to read a program written by an expert
- It’s a very small amount of code to complete the assignment, but the end result is a large system
- There are many simple follow-on assignments that can be generated by the students
Eventually, if a student spends some time following their interests to propose and make changes, they will expose themselves to more and more of the program, generate questions, and direct their own learning. In the end, they will get a lot closer to being able to create a program like this themselves.
I am using this approach now to learn clojure. With github, we have access to programs written by experts, and crucially, a simple way to fork and change them. This has been a great way for me to learn, and it just occurred to me today that I learned this technique nearly 30 years ago.