Authors Gunnar Rye Bergersen and Jan-Eric Gustafsson put 65 professional programmers through their paces for two straight days, tackling twelve meaty tasks in the Java language to prove their programming skill; this was what the study ultimately wanted to better understand.
Participants all filled in an extensive questionnaire on Java programming knowledge. Some participants also completed a suite of tasks involving memorising items (e.g. letters) while simultaneously handling another task such as checking sentences for errors. These measure working memory, the component of mind that keeps things available for conscious processing, and related to 'g', our proposed fundamental level of mental ability. Unfortunately working memory scores for over half the participants weren't taken due to logistical issues.
The authors modelled the relationships between all variables, including years of work experience, and found the best predictor of programming skill was programming knowledge: it loaded onto skill with a value of .77, where one would mean perfect prediction. Once knowledge was taken into account, a programmer's skill didn't benefit from better working memory or longer experience. Rather, these variables seem to matter earlier in the process by building better knowledge: working memory to help the programmer make sense of complex concepts, experience to provide the time for this to happen.
You can't get by in the programming industry with a static knowledge base, so working memory and a sharp mind will always be in demand in the profession. Indeed, observing that their data found an association between working memory and programming experience, the authors speculate that wannabes with poor working memory are more likely to leave the profession entirely. But this study asks us to recognise that a whizz programmer's competence is thanks to applying that brainpower to learning their trade.