Can Novice Programmers Write C Functions?

Cruz Izu, Peter Dinh · 2018

This work has analysed the solutions submitted by 301 students to a practical exam question from a CS1 course that covered C functions. We have focused on the ability of students to declare the function header correctly and to return a value to the main program. The analysis of exam's solutions showed that most students could write a function definition with the given name and number of parameters. Most mistakes were usually related to type, either in the function return value or in the input parameter. Besides, some students were inconsistent in that they declared a correct “int” function but instead of returning a value, they printed either the result or a message describing the output. It is worth noticing 16% of students developed a solution inside the main program instead of attempting to write a separate function, which indicates they have trouble understanding and writing modular code.

Read the paper · More papers on PaperTik