Name: Anonymous 2012-03-26 13:54
…and that you need to scrub more toilets if you disagree.
http://wadler.blogspot.jp/2012/03/empirical-investigation-of-influence-of.html
An Empirical Investigation of the Influence of a Type of Side Effects on Program Comprehension
I've bemoaned before the lack of empirical research on programming language design. Here[1] is one modest result, showing what you might expect, that side effects in expressions harm program comprehension. The sign of a good psychological experiment is surprise. While the result in this case is unsurprising, perhaps the observation of similar results for both inexperienced and experienced programmers is a bit more surprising.
This paper reports the results of a study on the impact of a type of side effect (SE) upon program comprehension. We applied a crossover design on different tests involving fragments of C code that include increment and decrement operators. Each test had an SE version and a side-effect-free (SEF) counterpart. The variables measured in the treatments were the number of correct answers and the time spent in answering. The results show that the side-effect operators considered significantly reduce performance in comprehension-related tasks, providing empirical justification for the belief that side effects are harmful.
[1] http://dx.doi.org/10.1109/TSE.2003.1214329
http://wadler.blogspot.jp/2012/03/empirical-investigation-of-influence-of.html
An Empirical Investigation of the Influence of a Type of Side Effects on Program Comprehension
I've bemoaned before the lack of empirical research on programming language design. Here[1] is one modest result, showing what you might expect, that side effects in expressions harm program comprehension. The sign of a good psychological experiment is surprise. While the result in this case is unsurprising, perhaps the observation of similar results for both inexperienced and experienced programmers is a bit more surprising.
This paper reports the results of a study on the impact of a type of side effect (SE) upon program comprehension. We applied a crossover design on different tests involving fragments of C code that include increment and decrement operators. Each test had an SE version and a side-effect-free (SEF) counterpart. The variables measured in the treatments were the number of correct answers and the time spent in answering. The results show that the side-effect operators considered significantly reduce performance in comprehension-related tasks, providing empirical justification for the belief that side effects are harmful.
[1] http://dx.doi.org/10.1109/TSE.2003.1214329