Syntax, Predicates, Idioms - What Really Affects Code Complexity?

Shulamyt Ajami, Yonatan Woodbridge, Dror G. Feitelson

Research output: Chapter in Book/Report/Conference proceedingConference contributionpeer-review

20 Scopus citations


Program comprehension concerns the ability to understand code written by others. But not all code is the same. We use an experimental platform fashioned as an online game-like environment to measure how quickly and accurately 222 professional programmers can interpret code snippets with similar functionality but different structures. The results indicate, inter alia, that 'for' loops are significantly harder than 'if's, that some but not all negations make a predicate harder, and that loops counting down are slightly harder than loops counting up. This demonstrates how the effect of syntactic structures, different ways to express predicates, and the use of known idioms can be measured empirically, and that syntactic structures are not necessarily the most important factor. By amassing many more empirical results like these it may be possible to derive better code complexity metrics than we have today.

Original languageAmerican English
Title of host publicationProceedings - 2017 IEEE 25th International Conference on Program Comprehension, ICPC 2017
PublisherIEEE Computer Society
Number of pages11
ISBN (Electronic)9781538605356
StatePublished - 28 Jun 2017
Event25th IEEE International Conference on Program Comprehension, ICPC 2017 - Buenos Aires, Argentina
Duration: 22 May 201723 May 2017

Publication series

NameIEEE International Conference on Program Comprehension


Conference25th IEEE International Conference on Program Comprehension, ICPC 2017
CityBuenos Aires

Bibliographical note

Publisher Copyright:
© 2017 IEEE.


  • Code complexity
  • gamification
  • program understanding


Dive into the research topics of 'Syntax, Predicates, Idioms - What Really Affects Code Complexity?'. Together they form a unique fingerprint.

Cite this