Asee peer logo

Common Logic Errors for Programming Learners: A Three-decade Literature Survey

Download Paper |

Conference

2021 ASEE Virtual Annual Conference Content Access

Location

Virtual Conference

Publication Date

July 26, 2021

Start Date

July 26, 2021

End Date

July 19, 2022

Conference Session

Computers in Education 2 - Programming 2

Tagged Division

Computers in Education

Page Count

18

DOI

10.18260/1-2--36814

Permanent URL

https://peer.asee.org/36814

Download Count

2342

Request a correction

Paper Authors

biography

Nabeel Alzahrani University of California, Riverside

visit author page

Nabeel Alzahrani is a Computer Science Ph.D. student in the Department of Computer Science and Engineering at the University of California, Riverside. Nabeel's research interests include causes of student struggle, and debugging methodologies, in introductory computer programming courses.

visit author page

biography

Frank Vahid University of California, Riverside

visit author page

Frank Vahid is a Professor of Computer Science and Engineering at the Univ. of California, Riverside. His research interests include embedded systems design, and engineering education. He is a co-founder of zyBooks.com.

visit author page

Download Paper |

Abstract

We surveyed common logic errors made by students learning programming in introductory (CS1) programming classes, as reported in 47 publications from 1985 to 2018. A logic error causes incorrect program execution, in contrast to a syntax error, which prevents execution. Logic errors tend to be harder to detect and fix and are more likely to cause students to struggle. The publications described 166 common logic errors, which we classified into 11 error categories: input (2 errors), output (1 error), variable (7 errors), computation (21 errors), condition (18 errors), branch (14 errors), loop (27 errors), array (5 errors), function (24 errors), conceptual (43 errors), and miscellaneous (4 errors). Among those errors, we highlighted 43 that seemed to be the most common and/or troublesome. As interest in computer science education continues to grow, with college majors tripling in the past decade, this survey can help instructors, authors, and tool developers focus on helping learners detect or avoid these common errors in CS1.

Alzahrani, N., & Vahid, F. (2021, July), Common Logic Errors for Programming Learners: A Three-decade Literature Survey Paper presented at 2021 ASEE Virtual Annual Conference Content Access, Virtual Conference. 10.18260/1-2--36814

ASEE holds the copyright on this document. It may be read by the public free of charge. Authors may archive their work on personal websites or in institutional repositories with the following citation: © 2021 American Society for Engineering Education. Other scholars may excerpt or quote from these materials with the same citation. When excerpting or quoting from Conference Proceedings, authors should, in addition to noting the ASEE copyright, list all the original authors and their institutions and name the host city of the conference. - Last updated April 1, 2015