Java Compiler and Runtime Errors
CS2 / Java
Abstract
Students often fear compiler errors and start panicking when their code does not compile. This activity teaches the students to read and interpret compiler errors. The activity emphasizes the fact that the compiler is just a computer program, and thus can be confused by bad input, resulting in too many errors or too few errors. Another common student mistake is treating code that compiles as code that works. This activity presents a scenario with a runtime error and helps students understand the difference between compiler and runtime errors. After completing this activity the students will be able to read and interpret errors generated by the Java compiler, fix compiler errors, and explain the differences between a compiler error and a runtime error.
This activity was developed with NSF support through IUSE-1626765. You may request access to this activity via the following link: IntroCS-POGIL Activity Writing Program.
Level: undergraduate
Setting: computer classroom
Activity type: Learning Cycle
Discipline: Computer Science
Course: CS2 / Java
Keywords: compiler errors, runtime errors, debugging
Downloads
Published
How to Cite
Issue
Section
License
Copyright of this work and the permissions granted to users of the PAC are defined in the PAC Activity User License.