Coding Kiwi ponders whether the recent developments in learning how to code such as Codecademy and Stack Overflow are actually producing developers that don't understand the fundamentals of coding at all.
With all the recent progress in getting the UK government to realise that we really should be teaching children how to program in schools, there is a lot of focus on fun new ways of teaching it. 

There are loads of websites / apps available for teaching kids coding. The most notable success story of late is Codecademy. Codecademy engages children through gaming culture; there are hundreds of coding exercises which the user can complete and earn points and badges along the way.

You just type the JavaScript right into the browser and it explains to you exactly what to do. This is pretty sweet, and definitely more engaging than just getting kids to read a book. 
An exercise on
However, this is where I think we have a problem. It's difficult to get kids to sit down and do anything, so the only real way to guarantee that they'll get stuck in is to let them code something right away.

It's good, but it's a bit risky. After all, the average Computer Science degree will teach you how to think about code, not to write it, and it is pretty universally agreed that this is a good idea, and not at all a waste of time. By teaching kids how to code in tutorial form, they end up knowing how to write an if statement to solve a specific problem, but do they really understand how control flows through the program, or know when you need to put an if statement in your code?

It's just teaching you to fill in the blanks:

Another exercise on, asking the user to fill in the gap in the if statement
recent blog post by Codecademy on how truly difficult it is to teach beginners to code when you can't remember all the little stumbling blocks along the way, prompted this discussion, which questions how valuable it is to teach in a tutorial-based format.  

The fundamental problem is my two friends need me to teach them how to think in code, how to conceptualize the problem, how to understand that "i am taking this problem, i am working out a solution in my brain, in english, and then i will write this solution in code" They simply do not have the capacity to do that. And they are 5 months in through codecademy.

Just yesterday my friend had the idea that when using a for loop, the loop passed all values at the same time to the nested switch statement, upon which the switch statement would evaluate ALL the variables at the same time, using whatever the hell case was the best match. He couldn't pass the level because he did not visualize in his head that the for loop passes each value, one at time. Then it procedurely flows down, line-by-line into the switch statement... and so on. My friends do not have pictures in their head about how code works, why it works that way, and how to use those pictures to draw their own.

They don't know how to code.

aspose at
I have to agree with the above. The point at which this becomes noticeable is when people taught in this way encounter a problem. This may be that their code doesn't compile or doesn't do what they wanted it to, but very frequently they just have no clue how to resolve the issue. While they generally understand what each line of code is doing, they lack the higher level knowledge along the lines of "why did we decide to use a for loop here in the first place?"

And the worrying thing is, that I would imagine a proportion of new programmers taught in this way would give up, and the rest would read a book or ask a friend that could take a step back and explain what is actually going on within their program.  That was before Stack Overflow.

Stack Overflow is a Q&A site for programming, and if you've never head of it before then I'm surprised you're reading this blog; it is incredibly successful.  It is a great resource for new (and experienced) coders because if you're having a problem with some code, you post it up there and you're likely to receive several answers pointing you in the right direction.  Suddenly if you’re not sure why your program isn't working due to a lack of understanding of the fundamentals, you can post your code up and get an answer along the lines of "change the third line to do this". The person that answered the question goes away happy that their program is now shiny and working, but they haven't really learned anything at all.

Of course, you'd hope that the person answering the question would give some guidance on why they need to change the third line of code, but this quite often consists of a link to some depressing MSDN documentation or API listing. 

There is a lot of this going on. It's really easy to Google how to make a cool menu bar, or a dialog, or any other programming task. My fear is that once the tutorial-taught programmers get out into the real world, the approach will become "find some code that does something like what I want to do, and get someone to tell me what to change so that it also does X".

There is a lot of this going on; here are a couple of examples:

The excellent blog post by Matt Gemmel at, addresses the kind of question that crops up along the lines of "I need some code to display a slideshow of images, how do I do that?" Although that kind of question bothers me, the ones I linked above worry me more. These are the kind of programmers that, if we're not vigilant, may get employed to write software you will have to use someday.

Peter Norvig's "Teach Yourself Programming in Ten Years", really reflects my concerns well. We're selling the industry short if we start to act like learning to program is something that you can do in a week. I personally spent about five years learning programming at school / University, followed up by several years of industry experience. 

What can we do about it? Let's slow down and emphasise the importance of understanding rather than achievement. Sites like Codecademy should try to back up their tutorials with a little extra explanation, and appreciation for the craft of writing code. And to all of the Stack Overflow users, when you tell someone to change line three of their code, please tell them why.



28/07/2012 9:15am

Anyone know where I can find more information?


Leave a Reply


    May 2012


    Learn To Code
    Stack Overflow