The Application of Code Plagiarism Detection Function in a C Programming University Course

C programming is taught as the first programming course at many universities worldwide. In most cases, students are required to submit their assignment answer codes through the university's system or by mail, which makes code plagiarism among classmates occur easily. When plagiarism occurs, the instructor cannot grasp the students' true level and then provide appropriate guidance, thereby limiting the improvement of their programming skills. In large classes, checking code manually is impractical, making automated plagiarism detection tools essential. In this paper, we implement a code plagiarism detection function to a C programming university course. This function detects plagiarism by the following steps: 1) removes all whitespace and comments using regular expressions. 2) calculates the Levenshtein distance and similarity score for pairs of source codes from different students. If the score exceeds a specified threshold, they are regarded as plagiarism. 3) reports the scores into a CSV file. For evaluations, the proposal was applied to a total of 1,688 answer source codes from 99 second-year undergraduate students. The results indicate that: 1) the plagiarism rate increases as the difficulty of the assignment increases, 2) the optimal similarity threshold differs across assignments, 3) some students often copied answer code from certain students.

Authors

Institutions

Publication Details

Published
2025-06-27
DOI
https://doi.org/10.1109/is3c65361.2025.11130958
Primary Topic
Academic integrity and plagiarism
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

The Application of Code Plagiarism Detection Function in a C Programming University Course

Khaing Hsu Wai, Xiqin Lu
Academic integrity and plagiarism
article

The Application of Code Plagiarism Detection Function in a C Programming University Course

Khaing Hsu Wai, Xiqin Lu
article en

Abstract

C programming is taught as the first programming course at many universities worldwide. In most cases, students are required to submit their assignment answer codes through the university's system or by mail, which makes code plagiarism among classmates occur easily. When plagiarism occurs, the instructor cannot grasp the students' true level and then provide appropriate guidance, thereby limiting the improvement of their programming skills. In large classes, checking code manually is impractical, making automated plagiarism detection tools essential. In this paper, we implement a code plagiarism detection function to a C programming university course. This function detects plagiarism by the following steps: 1) removes all whitespace and comments using regular expressions. 2) calculates the Levenshtein distance and similarity score for pairs of source codes from different students. If the score exceeds a specified threshold, they are regarded as plagiarism. 3) reports the scores into a CSV file. For evaluations, the proposal was applied to a total of 1,688 answer source codes from 99 second-year undergraduate students. The results indicate that: 1) the plagiarism rate increases as the difficulty of the assignment increases, 2) the optimal similarity threshold differs across assignments, 3) some students often copied answer code from certain students.

Ritsumeikan University (JP), Akita University (JP)
Openalex Percentile: Top 77%
Academic integrity and plagiarism
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.