Kids Programming
May 22, 2008
I recently decided my son Micah should be introduced to programming. He’s 9 now and being the son of a geek needs to know more than how to play games. I did a little research and found some useful learning tools.
I discovered a free online book called, “Snake Wrangling for Kids.” This is a great introduction to Python for kids 8 and up. I simply set him up with a PDF viewer and a Python shell in another window and let him go to work. I was simply there to answer questions and help if he didn’t understand things. It took a little bit to get him interested. You have to show kids what is possible because learning about variables and stuff is pretty boring if you don’t know their potential. I wrote a simple Python function (probably not the most efficient way to do this, but simple) to draw a Sierpinski triangle and even my 6 year old daughter became interested. Of course then we had to try running this with a hexagon instead of a triangle…
def sierp(turtle, size=200, sides=3):
for i in range(sides):
turtle.forward( size )
turtle.left( 360/sides )
if size >= 10:
sierp( turtle, size/2, sides )
An even easier (and probably more fun) place to start is Scratch. Scratch is a visual programming environment based on the Squeak Smalltalk engine. (Note that the website only mentions Windows and Mac versions, but if you dig enough there is a beta Linux version as well.) Scratch is set up to allow sharing of your creations on the Scratch website. Micah’s first Scratch “program” (created with some help) is viewable online.
