Code Quality and Large Language Models in Computer Science Education : Enhancing student-written code through ChatGPT

University essay from KTH/Skolan för elektroteknik och datavetenskap (EECS)

Author: Oscar Backström; Annie Kihlert; [2023]

Keywords: ;

Abstract: The increased digitization amplifies the significance of code quality in software development. Yet, it is often difficult for novice programmers to understand and produce high-quality code. This study aims to explore the effects of large language models (LLMs), more precisely ChatGPT, on the code quality exhibited by computer science students. The research questions addressed are: (1) To what extent can ChatGPT improve code quality issues? and (2) Is ChatGPT more prone to remove certain code quality violations? The study is limited to code written by students in introductory computer science courses at the Royal Institute of Technology in Stockholm, Sweden. The code quality was determined using a static code analyzer. The result showed that ChatGPT was able to improve the quality of the students’ original code, and that it tends to resolve certain violations over others.

  AT THIS PAGE YOU CAN DOWNLOAD THE WHOLE ESSAY. (follow the link to the next page)