Automatic grading of programming assignments: An approach based on formal semantics

Xiao Liu, Shuai Wang, Pei Wang, Dinghao Wu

Research output: Chapter in Book/Report/Conference proceedingConference contribution

51 Scopus citations

Abstract

Programming assignment grading can be time-consuming and error-prone if done manually. Existing tools generate feedback with failing test cases. However, this method is inefficient and the results are incomplete. In this paper, we present AutoGrader, a tool that automatically determines the correctness of programming assignments and provides counterexamples given a single reference implementation of the problem. Instead of counting the passed tests, our tool searches for semantically different execution paths between a student's submission and the reference implementation. If such a difference is found, the submission is deemed incorrect; otherwise, it is judged to be a correct solution. We use weakest preconditions and symbolic execution to capture the semantics of execution paths and detect potential path differences. AutoGrader is the first automated grading tool that relies on program semantics and generates feedback with counterexamples based on path deviations. It also reduces human efforts in writing test cases and makes the grading more complete. We implement AutoGrader and test its effectiveness and performance with real-world programming problems and student submissions collected from an online programming site. Our experiment reveals that there are no false negatives using our proposed method and we detected 11 errors of online platform judges.

Original languageEnglish (US)
Title of host publicationProceedings - 2019 IEEE/ACM 41st International Conference on Software Engineering
Subtitle of host publicationSoftware Engineering Education and Training, ICSE-SEET 2019
PublisherInstitute of Electrical and Electronics Engineers Inc.
Pages126-137
Number of pages12
ISBN (Electronic)9781728110004
DOIs
StatePublished - May 2019
Event41st IEEE/ACM International Conference on Software Engineering: Software Engineering Education and Training, ICSE-SEET 2019 - Montreal, Canada
Duration: May 25 2019May 31 2019

Publication series

NameProceedings - 2019 IEEE/ACM 41st International Conference on Software Engineering: Software Engineering Education and Training, ICSE-SEET 2019

Conference

Conference41st IEEE/ACM International Conference on Software Engineering: Software Engineering Education and Training, ICSE-SEET 2019
Country/TerritoryCanada
CityMontreal
Period5/25/195/31/19

All Science Journal Classification (ASJC) codes

  • Software
  • Education

Fingerprint

Dive into the research topics of 'Automatic grading of programming assignments: An approach based on formal semantics'. Together they form a unique fingerprint.

Cite this