Skip to main content

Easy as Pi, teaching 7-9 year olds programming

As I turned my head, a blackboard rubber travelling at what seamed 100mph whooshed past my ear leaving a trail of chalk dust. Luckily I wasn't the target, and it was a good job too, as the origin of this projectile was delivered by a former professional Rugby Player… Fast forward nearly 30 Years and things are very different, not only have blackboards practically disappeared from most classrooms but so has Victorian style discipline... Today the modern classroom is full of technology like electronic interactive white boards, projectors, laptops, laser pointers and video cameras and kids don’t pass notes around to attract the attention of their friends, they just secretly instant message them with their smart phone.

st mathews tech day

The new kid on the block is the Raspberry Pi, a pocket sized computer smaller than my old Donkey Kong Game and Watch, for those of you not old enough to remember the 1980’s, this was an early Gameboy type product.

When I first sat on the carpet in front of the TV and powered up my Raspberry Pi, I was hit with instant déjà vu, the nostalgia of my childhood and the vivid memories of the hours I spent copying program code into my Commodore 64 to execute a few basic programmes, and my sister complaining because she wanted to watch Saturday morning Swap Shop.

Determined for kids today to experience a little of what I did as a child, I recently spent some time in a school teaching 90 children, aged between 7 to 9 some basic python programming on Raspberry Pi’s.

Sue Black of the Goto Foundation has a mission to evolve and change the perception of computing in schools, so when she asked me to take part in the St Matthews School Tech Day, I was more than happy to be Obi Wan to the Padawan’s (that’s young Jedi’s in training for the non StarWars Geeks;0)

So off I went with the support of a couple of RS colleagues, Jo Bennett, and Dr Bill Marshal, also an old school computer geek, Pi advocate and DesignSpark blogger. For the kids, the day consisted of 3 sessions geared around App’s, Software and Hardware.  One of the sessions running was geared around “Scratch”, which is like a pictorial computing programming language ideal for young kids to get the concept of programming.  You can run Scratch on the Pi, but in our session we went “old school” and got the kids copying out some basic Python code to run simple programmes starting with “Hello World”

My idea was to get them to understand that programming was basically about writing a set of instructions to a computer in a language that it understands. It will then follow those instructions to perform a task.  To demonstrate this, I put together some exercises written in Python that they typed into a Python editor window.  When the code was run it would flash an LED on a small connected board that was hung off a couple of the Pi’s GPIO pins.

It was amazing to see how computer savvy some of these young kids are. A few of them picked up the basic Python Exercises very well, although some of the younger ones struggled a bit to understand that they had to copy the code exactly as written and missing a tab space or forgetting a capital letter would mean that the code wouldn’t run.

It’s important we capture and nurture the imaginations of this generation of kids.  Kids are smart, but if we don’t teach them this stuff from an early age, we are likely to lose a generation of Computer Scientists, Software Developers and Electronics Engineers.  If kids as young as 7 can get their heads around this, then there's no reason why the average school teacher can't!  So if you're a teacher reading this, get yourself a Pi, and together lets teach kids programming computers as opposed to just using them.

Let’s face it, thanks to Harry Potter and modern super geeks like Facebook’s Mark Zuckerberg and Tumblr’s David Karp, “geek” is now cool! and with super geek status, there’s super high salaries! Move over Hollywood superstars and premiership footballers, this is the age of the geek!

Watch Pete on the BBC at 


Some images with thanks to funkyphotographers

DesignSpark Team Geek Dad, Blogger, Gadget Junkie, Technology Evangelist. DesignSpark Team. twitter - @petenwood