I just found out today about a book that is available free on-line (or $25 for a paper copy): Invent Your Own Computer Games with Python. Unfortunately, both my son and I are past the point with Python where we can evaluate what a tutorial offers for a novice—and this book is clearly aimed at non-programmers, not programmers trying to learn a new language. I could look through the book and see whether it covers enough of what I consider the important programming concepts and features of Python, but I can’t tell whether it is accessible to a novice nor whether the material depends only on what has been presented so far—at least, not without taking very careful notes and analyzing it very methodically, which I’m not willing to spend the time on.
So, I’ve not read the book, but the premise looks promising: starting non-programmers writing Python to do simple games, gradually adding complexity. In Chapter 17, the book introduces PyGame, which is a suitable environment for developing simple graphical games. Note that this is much later than one would get to the same level of graphics and animation in a language like Scratch.
The authors chose to use Python 3.1 (rather than 2.7), which limits somewhat what packages are available, though that is probably irrelevant for this level of programming. It remains to be seen whether Python 3 will catch on with developers, or whether everyone will breathe a big sigh of relief that they have finally frozen Python 2 (with 2.7) and concentrate their development on a stable language, rather than having to rewrite things every year as the language designers change their minds about features. Python 3 promises to a be a moving target for several years to come.
Some things strike me as a bit strange about the book—like having a chapter on flow charts. I was taught to program using flow charts, back in the 1960s, but when structured programming became popular in the mid-1970s, flow charts were correctly recognized as leading to messy, unstructured code, as well as being a very inefficient use of space on the page. There are better ways to show decision structures graphically. The particular flow chart style they picked is very impressionistic (no way to assign semantics to it), so it isn’t clear that it would even help students organize their thoughts.
The advice I gave in Computer languages for kids still holds: teach Scratch first, then switch to Python when you want to do more text processing or are bumping into the limitations of Scratch. Whether Invent Your Own Computer Games with Python is a suitable book for Python after Scratch is debatable—I’d be interested in hearing what other people think of it.
Filed under: Uncategorized Tagged: computer science, education, programming, PyGame, Python, Scratch Image may be NSFW.
Clik here to view.

Clik here to view.
