Teaching Beginners to Code

This is the latest editorial from my newsletter, subscribe here.

For the past few months I have been teaching refugees from Syria how to program at the Redi school here in Berlin. The school has attracted a lot of attention since it began, with even Mark Zuckerberg paying a visit earlier in the year.

This experience, and others in my past, have caused me to think a lot about educating beginners, and the most effective ways to do so. At Redi we decided on Ruby (and Rails), but quickly realized that whilst it’s levels of abstraction and helpers appeal to experienced developers, they confuse beginners.

It’s been interesting to watch the recent rise in popularity of functional languages, which have reversed the rise of ‘do what you want’ languages with languages that force you to be more careful and considered. This of course brings many performance and stability advantages, but are still not very suitable for beginners.

I am working on a more in-depth article on the subject and would love to hear your thoughts on what languages are good for beginners to learn and why. I look forward to your responses!

5 Likes

Absolute beginners?
Nowadays in terms of web dev I’d say HTML first, CSS second, JavaScript third.

In terms of “programming” in general, I’d say it would have to be the first “language”: I learned, which really isn’t a language. That being Digital or Gate Logic.

You know, the AND, OR, NOR, XOR stuff. Great for understanding life in the binary dimension.

My first “real” language was BASIC, but I don’t think I could recommend that now, much has changed.

My second was Java, but TBH I don’t think it would be good for most as a beginning language. Though any that persisted and survived would have a good start.

I agree, I was actually thinking how much learning BASIC helped to learn program as it’s very obvious.

When I learnt BASIC I thought how stupid it was as a language - a huge backward step into chaos. Of course I already knew several other languages by the time BASIC was first invented. It might be different now but back then BASIC created the second worst convoluted code messes that I have ever seen (a close second to CoBOL alter goto statements).

My first language which I taught myself before ever gaining access to a computer to try it out was ForTran. The first language that I was actually taught in a class was Pascal and after learning that I could see all the flaws in BASIC when it was introduced.

As far as first programming language to learn now then JavaScript seems the most obvious as it can run everywhere.It certainly isn’t the easiest to learn though as everything in it is event driven and involves objects.

I really like this course:
http://www.ccs.neu.edu/home/matthias/HtDP2e/index.html

It’s a course in design, and helps beginners to program within the context of computation design.

I suggest, what most beginners never get from the language approach to programming is an appreciation for computation design. I have worked with many colleagues who still suffer from a lack of good design training in their formative years as programmers.

Dare to take a deeper look at this course - it may surprise you :slight_smile:

1 Like

That’s not a course in design - it is a course in how to design programs.

This has been one of my concerns with modern teaching techniques (and a core point in what I am writing) is that they are very focussed on practical ‘take homes’ and that theory gets lost. Understanding principles and design patterns is super important or coders will keep re-inventing the wheel.

What are people’s thoughts on Python as a learners language?

If you are keen on Python, look at this approach https://pragprog.com/press_releases/practical-programming-an-introduction-to-computer-science-using-python-3

Also this IDE has a entry level Python language course built in. https://www.jetbrains.com/pycharm/

I started to learn Python, having no real knowledge of any other language. I didn’t get very far before I got overtaken by life, but I hope to get back to it at some stage. I found it quite easy to grasp as a beginner; it remains to be seen how easy I’ll find the more advanced stuff.

Hi Chris,

I think Ruby is a great language for beginners to learn. There’s a great book called Learn to Program by Chris Pine that walks you through from the very beginning. It’s also available for free online:
https://pine.fm/LearnToProgram/

Ruby on Rails has a lot of ‘magic’ going on in the background that can be confusing for beginners. I’d recommend using Sinatra for building web apps instead. You can start with really simple applications and it helps you understand the concept of HTTP a lot more.

I’ve created a few resources that are on SitePoint Premium that you might find useful for this.

Hope that helps. Good luck, it sounds like a great project!

DAZ

1 Like

Coming from an art background, and someone who feels called to teach others myself, I would have to agree with ChrisChinchilla. Definitely learn CSS/HTML then javascript. Then I would move on to learning other software dev languages like C# and C++. Just a thought from someone who is a beginner myself.

For absolute beginner, I would start with teaching them constructs of programming like data structures, loops, etc… There is a great site called code.org that helps beginners learn programming and it is fun to do.

problem solving - once you know that half of programming the actual syntax of any programming language is relatively trivial. Plus if they are not good at problem solving then they will never be good programmers regardless of what languages they learn.

1 Like

Hi, a few years a go, I started to look into data visualisation and found that the processing language could be used as a good tool to teach computer programming from.

“Processing is a flexible software sketchbook and a language for learning how to code within the context of the visual arts.”

Something i found hard when at school was learning ‘principles’ without any context. Maths in particular was taught in a ‘you need to learn this because you need to learn this’ instead of ‘you need to learn this as you can apply it to X and Y in the real world’. Using Pythagoras to work out the length of the hypotenuse for example. without any context it is mostly pointless and i could use a ruler to find out how long it is. But when you realise that is can be used to work out the length of beam required for building a roof at a specific angle it gives it a use and a meaning that my brain can latch on to.

Some people won’t need this but i did. Although i do find logic much easier to do than maths. But again teaching the principles with a real world example for me would be important.

2 Likes

Do you feel that recommending people layer on more dependencies to make a language ‘more usable’ is a good step? Or is it adding more layers of confusing abstraction?

I agree with this, and feel that maybe not enough time is spent on teaching principles these days… We covered a lot of ‘pseudo code’ when I was at Uni.

1 Like

I’ve watched some processing lessons too, it does look pretty cool actually.

Buy one of these :stuck_out_tongue:

https://www.kickstarter.com/projects/primotoys/cubetto-hands-on-coding-for-girls-and-boys-aged-3

Even a 3 year old can learn how to program with that :slight_smile: