After much procrastination, I am finally posting the results of my research into how the frequent use of computer programming languages affect the brain.

As followers of the blog will remember, after reading theories about how learning languages affect the brain, I wanted to know whether computer programming languages also affected the brain. With a few notable exceptions (e.g. Murnane, 1993) most research about the cognitive effects of computer programming seemed to have focused on programming as a problem solving rather than a linguistic activity. If computer languages were indeed languages, I thought that it would make sense for them to affect the brain in a similar way to other languages.

This is quite a big subject, so I honed in on bilingualism. If computer programming languages are languages, then people who spoke one language and could programme to a high standard should be bilingual. Research has suggested that bilingual people perform faster than monolingual people at tasks requiring executive control – that is, tasks involving the ability to pay attention to important information and ignore irrelevant information (for a review of the “robust” evidence for this, see Hilchey & Klein, 2011). So, I set out to find out whether computer programmers were better at these tasks too. It is thought that the bilingual advantage is the result of the effort involved in keeping two languages separate in the brain and deciding which one to use. I noticed that novice computer programmers have difficulty in controlling “transfer” from English to programming languages (e.g. expecting the command “while” to imply continuous checking; see Soloway and Spohrer, 1989), so it seemed plausible that something similar might occur through the learning of programming languages.

Obviously, lots of bilingual people learn two languages from birth, and – young as some of them might be – this is clearly not the case for computer programmers. However, the effect has also been found in bilingual people who gained a second language in adolescence (Tao et al., 2011). Therefore, I compared 10 adolescent programmers (aged 14-17) and 10 professional programmers who had been programming since adolescence (aged 21-25) to age matched controls. All participants were monolingual English speakers.

I used two computer-based tests – Stroop and attention networks task – which required participants to pay attention to one thing and ignore others. Unfortunately, I made an error in setting up the Stroop test, so I can’t be sure that data is reliable. However, data from the attention networks task showed that computer programmers performed this task faster than controls and the difference between the two groups was significant (note that “significant” means that we are more than 95% sure that the results didn’t happen by chance – it doesn’t mean there was a big difference in reaction times). Error rates did not differ significantly.

This was only a very small study and I’d be reluctant to make any grand claims based on it; the results would need to be replicated by other studies. Even if other studies did support these findings, it doesn’t necessarily mean that computer programming experience causes better executive control; it might be that people with better executive control are more likely to persist with computer programming. If the latter is true, one way to help people learn computer programming might be to teach them a foreign language first. I did notice that a lot of programmers seemed to be bilingual – I think it would be interesting to do a survey to see if that is supported by hard facts.

Anyway, if you’re interested in picking apart the detail, you can download the full report here. If you do manage to struggle through, let me know what you think – random theories welcome! I’d love it if it gave people ideas for bigger studies. Huge thanks to everyone who took part and to all those who helped, especially the team at Young Rewired State. I couldn’t have done it without you all.