There’s been a lot of noise in the media about learning to code lately. Bill Shorten says all kids should do it. Tony Abbott says it’s a joke, despite it being part of his own party’s education policy. And more recently, Robert Merkel and Robyn McNamara argued that it was not such a great idea for kids to learn coding without the proper theoretical underpinnings. They talk about the risk of developing “Cowboy Coders” who just want to hack, and who don’t see the point of doing things properly.
There are two problems here. The first is that if we, as educators, can’t help students see the reason for learning something, then we are not teaching it properly. We have a terrible tendency to try to explain the reasons for planning and documenting things properly for problems that can be solved in 10 lines of code. Little wonder kids can’t see the point of careful planning – for a problem that size, there isn’t much point at all.
Or we teach the importance of efficiency when dealing with 100 values, when there is no difference to the naked eye between the best and worst possible algorithms. When your code runs faster than you can say “run time error” regardless of the algorithm you used, it’s hard to see why you would bother with the most efficient code possible. This is not the fault of the students coming in – it’s our fault for not designing the curriculum and the activities so that we can prove their importance.
The second issue is the reason I think it’s crucial that kids meet coding early and often: it’s our image problem. Many kids believe two things:
- Coding is a boring, solitary activity done in dark rooms with pizza and coke, by people who don’t like people very much.
- Coding is Hard, and I’m no good at it.
Number 2 is often pitched as a gender issue, but I see it as an access issue more than a gender issue. The more exposure you have to coding, the better your chance to find out whether you are any good at it or not – and more importantly, whether you enjoy it. Where it becomes a gender issue is that girls are rarely encouraged, whether by teachers, relatives, or marketing, to play with technology, whereas boys are. Think that’s nonsense? Check out the “shop for girls” vs “shop for boys” images I took from Google last night:
Actually the contrast there makes me feel rather ill, but that’s another post.
Kids who meet code get to find out that they can do it, that it can be fun, and that it’s not a solitary activity for antisocial pizzavores. I’ve lost count of the number of students who have told me, often with some degree of shock, that they’re actually enjoying this code stuff in ways they never expected to. If they’d never tried it, they’d never have had the chance to find that out. And that would be a tragedy.
In fact, the cowboy coders that Merkel and McNamara describe are precisely the people who were attracted to coding because of its solitary, dark-room, caffeine fuelled image. If we introduce a wide variety of people to coding, and present it as a collaborative, exciting activity, we have the chance attract a whole different set of personalities to computer science. People who are attracted to the discipline for a whole new set of reasons, who can bring a whole new perspective to it. I’ve already seen this happen at my school.
More importantly, a whole new set of people can find out whether code is something they are interested in. There are huge numbers of people out there who would be great at code if they ever had the chance to find out.
The first step, of course, is finding the teachers who would be great at code, given the chance, and giving them that chance. Without enthusiastic, skilled teachers, the whole idea is going to fall very flat indeed.