We want undergraduate students to develop higher-order thinking skills that enable them to master program behaviour. Nonetheless, many students of both introductory and advanced programming courses appear to struggle with the abstraction required for this purpose. In particular, a recent think-aloud study showed a group of students were able to reason about and reverse the effect of assignments and vector updates, but most of them failed when asked to reverse a seemingly simple conditional statement.
We have extended that study by assigning a similar task to two cohorts of novice programmers as part of their final exam paper.
Students' answers, including code and short explanations, have been analysed through the lens of the SOLO taxonomy: 28% of the solutions were correct (classified as relational); an additional 23% were partially correct but failed to identify the overlap between the two paths of the conditional statement (classified as multistructural).
Furthermore, the concept of reversibility and related ``low-ceiling'' tasks, such as the one discussed in this study, could be useful resources for educators to assess and develop students' understanding of program behaviour.