In cognitive neuroscience, fMRI is an often used technqiue to visualize internal cognitive processes. We set out to evaluate whether we can use fMRI to measure program comprehension. To this end, we conducted two pilot studies to select suitable material.
Our paper about the study at the International Conference on Software Engineering
All tasks we used can be downloaded here
Tasks for session in scanner. First comprehension task, followed by syntax task in same row:
Comprehension task | Syntax task |
---|---|
Factorial | Decimal to binary |
Check if substring is contained | Cross sum |
Find largest in list of numbers | Reverse array |
Reverse string | Check if substring is contained |
Swap | Find largest of three numbers |
Power | Reverse string |
Median | Factorial |
Reverse array | Swap |
Cross sum | Median |
Find largest of three numbers | Power |
Count same chars in two strings | Find largest of three numbers |
Decimal to binary | Count same chars in two strings |
The results of the first pilot study, that is, response times and correctness, are available here
The results of the second pilot study, that is, response times and correctness, are available here
Answer of the participants after the session in the scanner, including their programming experience.
Answers (csv)
Confounding parameters and how we managed them (Framework for Measuring Program Comprehension for more details).
Confounding parameters (pdf)