Code Club: Week 5
16 May 2013
De Beauvoir Primary is about 400 metres from Studio 100, where I work. Last week, I decided to capitalise upon this proximity by running an extra lunchtime session on Wednesday. I honestly think this is one of the best decisions I’ve made so far running the club. Instead of the usual twelve students I got four; two of whom are usually a bit quieter in the after school club.
We used the time to finish off fruit machine, one of the more challenging projects from Code Club Term One. In spending a little longer working with each student, it became clear that at least one has developed a true intuition for the mechanics of programming in Scratch. Working rapidly through the step-by-step instructions and jumping head first into the unaided exercises at the end.
I’m not sure how, but we managed to squeeze almost an hour out of the lunchtime session. I was elated at the progress I’d seen, and enthused for the next day’s club.
Fish Chomp is one of my favourite of the code club projects. The gameplay is simple and fun, it encourages students to record their own sounds, and it leaves plenty of room for adaptation. Added to all that good stuff, it also incorporates something close to a Random Walk algorithm for the runaway lobsters.
From personal experience, learning about algorithms like this is a real eye-opener. They’re simple, unpredictable, and produce almost life-like results. Things get even better when you discover algorithms to simulate 2D and then 3D physics.
While these sorts of algorithm’s tend to make sense quite quickly, I’ve noticed some of the students have taken a while to get used to the idea of context. Code and variables relate to a particular sprite, and you need to make sure you click on that sprite—that you’re in its context— to be sure you’re editing the right stuff. But then some code and variables relate to the stage as a whole, so then you need to make sure you’re in the stage context. And sometimes it’s not clear who the code should belong to, so then what?
My own grasp of “context” in programs is something I’ve developed over
the years through trial and error. Furthermore, it differs from
environment to environment and language to language.
Sometimes context is characterised by what
self mean at
any given moment, sometimes it’s more implicit than that.
The students are getting a grip on it now though, and it’s another example of a programming concept learned early and naturally thanks to Code Club.
I should briefly mention this year’s superb Scottish Ruby Conference. The line up of speakers and atmosphere was just brilliant. So brilliant, in fact, that I got up the courage to deliver a little lightning talk on Code Club.
The slides are below, though they won’t make a whole lot of sense without the video. Watch all the lightning talks right here.