Teaching students to code

Mine were art and music, in Canada, you have to at least take one to get your HS diploma. Thank goodness for media art (think art on the computer, photoshop, etc).

The Little Schemer, cool find, have to check that out.

Yeah, I suffered from that too. I only learned as an adult that 90% of music theory is math, and very simple math at that: harmony is a good approximation to integer ratios of frequencies, the Circle of fifths is simply a minimum distance traversal across major scales, and the rest follows from that (for Western music).

Thanks Tamas,

I have a similar experience and opinion, except that I would add Introduction to phylosophy, which was just another name for history, painting, chemistry, etc. I especially like when people say that history is important for not repeating the same mistakes. Really?

1 Like

Those who don’t know history repeat the same mistakes made in the past.

Those who know history get to sit and watch helplessly.

(and here I am. attempting to make a joke despite my history of failure at joke making :slight_smile: )


As someone that worked briefly in an IT department, as quality assurance, and helped the analysts to get the project requisites from the users, I would say that the life of a lot of people in that position would be vastly improved if every user had studied the basic concepts of computation and algorithms in high school.

1 Like

One thing is certain about History. It is an extremely powerful drive .How we learn it, deal with it? Unknowns.

I think teaching history, geography and philosophy is way more important than teaching computer programming for high school students. Again, it is possible to teach those badly, or well, motivating students or not. The same with computer programming.


My point on History is that it is super cool, if taught properly. For example the History of Mankind is really nice. But I was not lucky for teachers, so it was only who has died when and where he ruled for how long.

As a Lecturer on university I struggle with students being very good at memorizing, but being lazy / having troubles to understand. I frequently ask them, why is it so and they replied that it is just easy for them to memorize and forget.

So I welcome any subjects on highschools and below that would prompt kinds to think over memorizing.


I had 4 years of both art and music at school, 2 hours per week. If this would be shortened by 1 year each, one could teach 2 years of computation / programming, which would be sufficient to give the students at least a basic understanding of this subject.

In the days of my youth, we had “labor” lessons, where we were taught how to work at the factory or we were cleaning streets or we were harvesting potatoes from the community fields. Also we had “basics of the security” lessons where we were taught how to count seconds between nuclear flash and explosion sound in order to estimate your remaining lifetime.

Computer science classes are not that bad, I think. It can be worse.


In combination with Marxism-Leninism in History, Social Studies, Geography and everything else actually quite good for the development of critical thinking.

The most common mistake I observe in policy discussions around CS education is the assumption that programming classes are vocational training. That can be the case, but the merits of any proposal depend very much on the nature of the learning that can be expected to take place.

I’d suggest that it’s better to think of CS more like math, which provides an extremely useful set of conceptual tools for interpreting the world and solving problems. Programming is about building well-structured, efficient systems, and many of those lessons carry over into other types of systems as well (e.g., bureaucracies, supply chains, etc.). I see CS’s importance as comparable to math in this respect. Perhaps even more so, potentially, since it can readily be made to feel vivid and real to students.

Perhaps an important question to ask is whether a student’s time will have been wasted if they don’t end up directly using the skills they acquire. If you think of CS as tedious job preparation, you would presumably answer affirmatively. But it’s worth doubting this conclusion.


The UNESCO has been working on this topic since the 90s. See for instance the 2019 report Coding, Programming and the Changing Curriculum for Computing in Schools.


I assume that many (most?) people in this community are self-taught when it comes to programming (cf this topic). We

  1. wanted to learn to code, usually badly enough to overcome various obstacles (hardware and learning material was much harder to access in the 1980–1990s and even later, compared to today),
  2. ended up liking it (otherwise we would not be using Julia, or any programming language),
  3. acquired a lot of relevant additional skills during the process (learning something on your own is always educational, even counting the rabbit holes and the difficulties you encounter).

Reflecting on this, I realized that I do not really have a good mental model for why someone would not want to code if they are otherwise interested in STEM, and if they want to, what prevents them from doing so. It is easier than ever if you have access to a computer and the internet.

The exception may be children from disadvantaged socio-economic backgrounds who may not be aware of the possibility. I think that the best approach is to address that, with programs like


You raise a really good point, and I agree with a lot of it, but I think awareness of the possibility and/or lack thereof extends far beyond socioeconomically disadvantaged kids. At least in my own case (you may be different), I received huge but implicit benefit from being raised in a family that was highly educated and who conveyed a “can-do” sense about learning; if I asked enough questions my parents didn’t know the answer to, I could pretty much predict that a trip to the library would be on the agenda soon. Enough experiences of being turned loose in the stacks and told “here’s how you figure things like this out, now go do it” and the message sticks and starts generalizing to other things. We were not financially rich, but I have no doubt that when it comes to inheriting an adventurous intellectual spirit I was lucky to be born with a silver spoon in my mouth. Professors tend to breed professors, and genetics & raw talent explains only a small part of that.

For that reason, my sense is that things like realizing that it’s even possible to self-teach programming—independent of that person’s potential for doing it successfully—may be distributed very unequally across the population.


That a nice summary. I have say that me experiences are similar to those of Tamas.

I work at an applied research institution and we have a lot of students, mostly studying chemical, biological, medical, environmental engineering, with an occasional chemist, physicist or mechanical engineer. At least some of them are indeed interested in STE (but likely not M). Mostly they had some kind of CS in their curricula.

They do experimental work, they do some processing of data using Excel, Origin, sometimes ImageJ and other tools. Some tasks could be probably made less time consuming by investing (probably more) time into writing scripts. I would - just because it’s more fun than doilng repetitive tasks. They mostly wouldn’t.

In many cases the systems under research/development are so complicated that no reasonable modelling is possible. Where it is possible, it would make rather sense to use a serious commercial package like COMSOL than to start from scratch.

It appears to me that nowadays in many STE fields one doesn’t really need any serious coding (and mathematical) skills - you got powerful tools ready to use, you don’t have to build them yourself.

Maybe it is only implicit in the context (see the opening post of the topic), but I was talking about primary- or secondary-school students. I think that at that age, interest is not that narrowly focused and learning a bit about various things, even if they are not directly practical or applicable, is more important than being productive (as in a day job).

Yes, at least where I currently live (Western Europe).

No, at least not in high schools.

I wish the high school students would learn (again) to read and write comprehensively, understand basic mathematics and structure, and learn to appreciate literature and the natural and cultural world that surrounds them. Also, I wish for them to get their heads out of their screens and get some fresh air from time to time.


You spoke about self-motivation to learn coding. If a kid is interested in technics and build robots - surely that’s a motivation to learn coding. If he is interested in explosions - that’s motivation to learn chemistry, but not coding. Similarly an interest in pets may lead to learning about genetics and DNA, but not coding. That is not qualitatively different from university students.

As for what is important: Any learning, any skill is useful in some broad sense, even if afterwards never applied directly in the real life, be it musical theory, ancient Greek or Euclidian geometry.

P.S. “He” instead of “(s)he”, “them” etc. is intended.