Warning: Parameter 1 to wp_default_scripts() expected to be a reference, value given in /homepages/0/d445017526/htdocs/wordpress/wp-includes/plugin.php on line 546
Programming's not for everyone - Journal of Interest
Warning: Parameter 1 to wp_default_styles() expected to be a reference, value given in /homepages/0/d445017526/htdocs/wordpress/wp-includes/plugin.php on line 546
19 Dec

Programming’s not for everyone


I used to think, as I suspect that most people think, that near enough everyone can learn to program if they were to put their mind to it. Recently I’ve been questioning this idea, and now I think probably not everyone can – probably less even than half. There seems to be a lot of websites out there encouraging everyone to learn to program, but I think all these programmes are necessarily doomed to failure if their intention is genuinely to get general society to understand programming.

But before I get into the meat of it, I’d like to preface it for the sake of those who find the idea that not everyone is capable of programming to be unpalatable. There’s a danger with ideas like this that they can be attacked as the simple self-aggrandisement of the can’s by people rising in defence of the can-not’s. An interesting offshoot of the movement towards equality between social groups is that society has now developed a tendency to treat with contempt nearly all forms of discrimination, except where it’s physically ingrained into our way of life (such as discrimination between skill levels in job applications).

To illustrate this, suppose for the sake of argument that a reputable study showed that, statistically speaking, and with all other factors reasonably controlled for, women held on average lower IQs than men. Such a study, I imagine, would be condemned as sexist. Similarly, if a reputable study exposed a disparity between the average British black person’s IQ and the average White person’s,1 there would again be heavy criticism, this time on grounds of race.

I’m sceptical whether similar levels of criticism would be drawn if these hypothetical studies had criticised men or white people respectively, for whom there generally exist few groups to champion their interests when speaking in terms of equality, though both are nevertheless discriminated against – especially men.2, a certain number of people shift in their seats as their idea of people each as a walking tabula rasa3 is challenged.

The first observation one might make when approaching this topic is what kinds of skills programming involves, and then ask to what degree each skill can be learnt. The following is a list of skills I would put forward as being causally correlated with programming ability.

  1. Attention to detail. Computers have no understanding of what they’re being used for – they don’t think. A program is a long list of very precise instructions that the computer will execute faithfully without question. There is no room in programming for a programmer to be in any way vague or ambiguous as to the logic of the code, without the output of the program being to that same degree vague and ambiguous. A programmer requires the attention to detail to specify every action of his program; the computer won’t fill in the blanks for him.
  2. Problem solving. Programs are written to solve problems, and in order to create a program, the programmer must solve its intended problem. The harder the program, the more difficult the problems involved, the greater the programmer’s problem solving ability need be. Programming requires two categories of problem solving – the first is abstract: how to structure and design the program. The second is logical: how to break down the required tasks into a set of logical steps.
  3. Analytical induction. Induction is the ability to take observations and evidence and apply them to construct general principles relating to the world. For a programmer, this means the ability to understand other people’s code by making observations about the techniques being employed, and from it infer what the code is intended to do. Any programmer worth his or her salt must be able to learn to work with others’ code.
  4. Good memory. A programmer must have the ability to remember the rules and idiosyncrasies of his language, as well as the relevant details of his program’s operations. There are many pieces of technical information that must be readily on call to the programmer whilst he’s working, and a better memory means less time spent consulting documentation and therefore leads to greater productivity. The ability to remember technical specifics, as well as abstract concepts such as design patterns, goes hand in hand with overall programming ability.
  5. Creativity. Creativity is in many fields the distinguishing factor between technical brilliance and genius – programming is no exception. The programmer who is able both to think within the rigid rules of his language, yet also able to bend those rules to accomplish the non-obvious, has a distinct advantage over another who can only do one and not the other. It seems to me no great surprise that some of the best programmers have also created their own languages.4 Creativity is critical where problem-solving requires a person to think ‘outside the box’, as difficult problems often do.5

Of these skills required by programmers, some will have them more than others, and if these are the major factors involved in one’s overall programming skill, then the degree to which these can be learnt will correlate with the degree to which a person can improve as a programmer.

To a degree, I think most of them can be learnt – but none of them to any great degree. A good memory is perhaps the easiest – while the fundamental short-term memory capacity is unlikely to change, nor the rate at which new information can be reliably absorbed, a person can still populate their memory over time, even if it happened to be a slow process. Most people probably could, if they wanted to, learn the ins and outs of an entire language specification. Certainly one’s knowledge of programming languages will increase as time spent programming increases.

Problem solving and analytical induction likewise – whilst one’s fundamental ability to solve new types of problems is unlikely to change,6 some types of problems are more common than others. Regular exposure to the same types of problems will be likely to improve a person’s ability to gain familiarity with the specific line of reasoning involved, and improve their competency with solving them.

Creativity and attention to detail, however, I think are unteachable. Creativity perhaps more obviously than attention to detail, because creativity deals exclusively with the identification of novel approaches. Creativity itself therefore can’t be practised – a person can expose themselves to new problems, but they can’t improve at finding the answers to problems with solutions they’re unfamiliar with because those solutions will always be unfamiliar. All a person can do is increase the domain of solutions that are familiar to him. Creativity, however, is not the crux of programming ability – I think a lot of people get on well with programming precisely because it doesn’t demand too much creativity from a person. If one subscribes to the view that people are either ‘left-brained’ or ‘right-brained’, then programmers are usually left-brained. It is very rare to see a programmer who is also an artist, but the ones who are tend to be good at both.

Attention to detail, on the other hand, is a crux of programming ability. If you can’t specify all the actions necessary for your program to operate, the program can’t help you out. Fundamentally, to be a programmer, you must have this skill.

From my experience at university, I don’t think it can be learnt either. The people who tended to do well after 4 years were the same people who tended to do well immediately after starting. Some people could decompartmentalise an idea into a series of discrete steps, and others could not. Nobody started bad at this and ended good. Indeed, I haven’t so much as heard of a person who started mediocre and became noticeably talented (not just knowledgeable) – the very idea of it is alien. One’s potential as a programmer seems obvious right from the off. Some have it, some don’t. I see it also in myself – though I feel competent in most areas, my creativity is my greatest short-coming, and it will always provide a ceiling to my potential as a programmer.

There is also the phenomenon of people coming out of university computer science or related courses applying for jobs as programmers, and subsequently being discovered not to be able to program. This is such a pervasive phenomenon that interviewers have had to become savvy to it and issue basic programming tests (I myself had to program a website in an hour to read, write and sort various data from a database using PHP and JavaScript for one job7. My course was in software engineering,8 for which there was much emphasis on programming, but I was positively surprised when it first dawned on me that my classmates still couldn’t program in the second year. I would say of most people in my graduation year that they couldn’t program, despite all their programming coursework. I’d also say that it’s almost impossible for someone who doesn’t program in their spare time to legitimately be said to have learnt to program. Simply doing coursework is not enough. These people also are of the impression that they can program, in a style reminiscent of the Dunning-Kruger effect.

Imran Ghory has a fascinating blog post about his experience with interviews for programming positions. He writes:

After a fair bit of trial and error I’ve come to discover that people who struggle to code don’t just struggle on big problems, or even smallish problems (i.e. write a implementation of a linked list). They struggle with tiny problems.

He tasks candidates with writing a simple program that prints the numbers 1 to 100, but instead of printing multiples of 3 it prints ‘Fizz’, and instead of printing multiples of 5 it prints ‘Buzz’. For multiples of both 3 and 5, it prints ‘FizzBuzz’.

Most good programmers should be able to write out on paper a program which does this in a under a couple of minutes.

Want to know something scary ? – the majority of comp sci graduates can’t. I’ve also seen self-proclaimed senior programmers take more than 10-15 minutes to write a solution.

During the research for this essay, I came across a study that reinforces my anecdotal evidence (which I’m glad I don’t have to rely on). Saeed Dehnadi and Richard Bornat claim to have discovered a method to determine who are ‘programming sheep’ and who are ‘non-programming goats’.9 They’ve created a test (a trivially easy one for professional programmers) that they say gives high accuracy in determining this divide before the participants have ever seen a program or programming language.

Their findings suggest a ‘double-hump’ distribution of programming ability – each hump an individual bell curve plotting programming aptitude against the number of people with that aptitude. What they also found was that when they readministered their programming aptitude test after 3 weeks’ worth of tuition and assignments, people didn’t improve. There was no migration from one bell curve to the other, and the results were practically identical.

I expect that continued confirmation of findings like these will change the way educational institutions teach programming and computer science. If people show no hope of improving during the course of tuition, and can easily be detected prior to course admission, they may as well be spared their tuition expenses and, where courses are full and people turned away, be discriminated against in favour of those who will benefit from the course, or in other cases warned that they should carefully consider whether they accept the risk of investment.

What is interesting is that in addition to static programming aptitude, there is also a wide range of possible aptitudes. One truly exceptional programmer can’t be replaced by any number of average programmers. The exceptional are so good that they dwarf average programmers, and the average programmer is so good that he too dwarfs programmers with little aptitude.

I don’t think that programming is an exceptional case – I just think it’s managed to fly under the radar for a while. I expect that there are other fields where natural aptitude plays a significant role – these, I would guess, would be ones that required similar sets of skills that are difficult to learn. Mathematics could easily be similar – while it is easy to learn basic maths, I wouldn’t be surprised if large numbers of people fundamentally wouldn’t be able to grasp certain mathematical concepts. Physics as well, to the degree that it also relies on technical concepts, though popular science publications do a good job of making these accessible to the lay person by means of analogies.

I would go further than just to say it applies to technical fields: I think it would also apply to those fields that rely on empathy. Teaching, for example, seems to me to rely heavily on teachers’ intuition and natural ability, though significant effort has been made in regard to what can be taught: lesson structure, techniques for dealing with difficult children, etc. I think there teachers who have a natural ability to relate ideas to others, and likewise the ability to capture the interest of students, and these abilities, insofar as they rely on gut-instinct, would be difficult to teach such that anyone could learn them.

With mathematics, scientists and teachers, there also exists this same impasse between the average and the great. Supposing there was a reasonable method to determine teaching aptitude, I would also expect people to fall into a double-humped distribution of aptitude for each of these three fields.

Art fields too would seem to match this case. Though I think almost anyone could become quite accomplished with drawing, painting, piano, etc., if they did it every day for the rest of their life, I think they only could do so to the degree that these activities could be distilled to the mastery of distinct techniques. A piano player could, for example, master fingerwork, rhythm, and even I think emotional nuance,10 but only some of these players could compose original music.11

I’m aware writing this piece that there’s a danger of sounding smug by virtue that I do work as a programmer and I’ve spent the last twenty paragraphs talking about the people I think definitely can’t. I’ve tried not to of course, but to a degree it comes with the territory. In our quest for equality, we risk glossing over the ways in which people are actually different from one another. Not everyone is the same or can learn anything they put their mind to. This idea is uncomfortable because it grates with our idea that people can accomplish nearly anything if they work hard enough for it.

What I would advocate instead is that people pay attention to what their aptitudes are, and being that it’s more enjoyable to do something well than not,12 we might find that our preferences naturally drift in that direction.

I wrote this piece for three reasons. Firstly, it’s an interesting subject and I wanted to explore it more. Secondly, it challenges established views that aren’t in harmony with the evidence.13 Thirdly, I wanted to stress the importance of understanding where both our talents and our deficiencies lie, because our careers are significant parts of our lives, and it’s important to choose ones we’ll enjoy. A person could conceivably enjoy a job they weren’t good at, but I don’t think we’re generally built that way.

All this having been said, I would encourage anyone to have a go at programming, since if you can do it, you’ll probably enjoy it.

  1. Actually, at least in America, there is such a gap, only nobody will touch it out of fear of being branded racist. This is a sad irony because if anything has the power to raise racial equality in America, it’s to address this issue. Stereotypes will always persist if they’re reinforced by everyday experiences, and so the best way to break a stereotype is to make it false, so that it requires from a person an active effort to refute regular experience that argues to the contrary. Stereotypes naturally fail when they’re continually confronted with information that contradicts them. The real problems here are social policies that encourage racism. Provide equal access to education (i.e., don’t let poverty become a self-fulfilling prophecy) and the stereotypes will take care of themselves. 

  2. One need look no further than nations’ rape laws to see some of the hurdles of future society. In England, for example, rape is still an offence that can only be committed by men (as its legal definition requires the use of a penis).[/ref] Science, however, is impartial and reports the facts, and what we must do as a society is ask ourselves only what are the facts, and not what we would like the facts to be.

    So it is in this case, where though the idea that not everyone has the ability to learn to program will not be pleasing to all, it nevertheless may be the case and so should not be casually dismissed by emotion rather than reason. I offer this defence explicitly because I’ve found from my experience in forum debating that often when one suggests that any group may in some sense be intrinsically different to another (especially in regards to some mental capacity ((Another subject I have been criticised for talking about are the differences between male and female psychology, where it is known that men and women are often attracted to each other according to different criteria; each gender shaped in the evolutionary environment in accordance with differing proportions of risk and reward. Often people who have not encountered the topic before do not accept these differences, however, and misinterpret them as another manifestation of sexism). 

  3. Tabula rasa is the term first used by philosopher John Locke for the idea that people don’t come pre-loaded with inclinations or biases towards one thing or another, rather that we are all at birth a ‘blank slate’, which is subsequently influenced. This idea evolved into psychological behaviourism in the early 20th century, which put forward the idea that all behaviours are learnt, none being innate. Unfortunately, both of these ideas do not match the evidence, which suggests that genetics holds far more sway than we’d often like to admit. The idea of ‘human nature’ is regularly dismissed or marginalised, but I expect this attitude will change over the next 50 years in line with a continued increase in scientific literacy. 

  4. Though this claim could be a product of sample bias. 

  5. Indeed, it borders on tautology to say difficult problems require creative solutions – if the answer to a problem was straight-forward then the problem would necessarily be less difficult. 

  6. This is the reason why, contrary to popular belief, a person can’t improve their score on IQ tests through practice. 

  7. I felt I did a poor job of it because I spent too long debugging a database connectivity issue and so was given extra time to complete the tasks. After that, noticing how many other people were also being interviewed, I had almost resigned myself from expecting to get the job, only to be offered the job anyway a week later. My only explanation for this is that my competition must have fared even worse than I did). 

  8. Software engineering, I am now convinced, is a dull field, starved of the technical beauty of computer science and drained to a grey marsh of generalisations. 

  9. Their publications can be found on Saeed Dehnadi’s website

  10. This is because I do not believe there must necessarily be any legitimate connection between real emotion and playing style. What might be called ‘emotion’ in playing style, could just as well be thought of as a product of timing, force and other elements. I once heard of a music teacher who categorically wouldn’t believe that a computer could hypothetically play a piece of music (from sheet music input) with this kind of nuance, however I wouldn’t be at all surprised if someone wrote software to do it well enough to fool humans – that is, if someone hasn’t already done it. 

  11. My own experience of piano puts me firmly in the category that cannot compose new music. I’ve played for over 7 years, yet cannot play much of anything by ear. It’s a skill I don’t expect I’ll ever develop much of, but I enjoy to play regardless. 

  12. Actually, it’s probably more accurate to say that, as humans, we enjoy being able to do things better than others can. 

  13. I must admit, though, that the view that most people can learn to program was not nearly as well supported amongst the programming communities I visited in research for this essay than I expected it would be. Among experienced programmers, the claim that not everyone can program is probably already well supported. 

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>