ABSTRACT
Teaching students to develop code of good quality is important. Refactoring -- rewriting a program into a semantically equivalent program of better quality -- is a common technique to improve code quality. It is therefore relevant for students to learn about refactoring, even for the smaller programs they write as beginners. However, students make mistakes when refactoring programs. Some of these mistakes appear often, and might be caused by misconceptions they have. In this paper, we investigate common student code refactoring misconceptions. We do this by analyzing log data containing program snapshots of students working on refactoring exercises in a tutoring system. We manually inspect all transitions from a correct program state to an incorrect state. We then use grounded theory to identify and categorize misconceptions students might have when refactoring programs. As a result, this work (1) defines the concept of refactoring misconception, and (2) provides an initial list of 25 such misconceptions, together with an accompanying website with full details.
- Vicki L Almstrum. 1996. Investigating student difficulties with mathematical logic. Teaching and Learning Formal Methods (1996).Google Scholar
- Jecton Tocho Anyango and Hussein Suleman. 2018. Teaching Programming in Kenya and South Africa: What is difficult and is it universal?. In Koli Calling.Google Scholar
- Kent Beck and Martin Fowler. 2018. Bad Smells in Code. In Refactoring: improving the design of existing code. Chapter 3.Google Scholar
- Anastasiia Birillo, Ilya Vlasov, Artyom Burylov, Vitalii Selishchev, Artyom Goncharov, Elena Tikhomirova, Nikolay Vyahhi, and Timofey Bryksin. 2022. Hyperstyle: A Tool for Assessing the Code Quality of Solutions to Programming Assignments. In SIGCSE.Google ScholarDigital Library
- Jürgen Börstler, Harald Störrle, Daniel Toll, Jelle Van Assema, Rodrigo Duran, Sara Hooshangi, Johan Jeuring, Hieke Keuning, Carsten Kleiner, and Bonnie MacKellar. 2018. " I know it when I see it" Perceptions of Code Quality: ITiCSE'17 Working Group Report. In ITiCSE.Google Scholar
- Dennis M Breuker, Jan Derriks, and Jacob Brunekreef. 2011. Measuring static quality of student code. In ITiCSE.Google Scholar
- Neil CC Brown and Amjad Altadmri. 2017. Novice Java programming mistakes: Large-scale data vs. educator beliefs. Transactions on Computing Education (2017).Google ScholarDigital Library
- Yuliya Cherenkova, Daniel Zingaro, and Andrew Petersen. 2014. Identifying challenging CS1 concepts in a large problem dataset. In SIGCSE.Google Scholar
- Luca Chiodini, Igor Moreno Santos, Andrea Gallidabino, Anya Tafliovich, André L Santos, and Matthias Hauswirth. 2021. A curated inventory of programming language misconceptions. In ITiCSE.Google Scholar
- Rohan Roy Choudhury, Hezheng Yin, and Armando Fox. 2016. Scale-driven automatic hint generation for coding style. In ITS.Google Scholar
- Giuseppe De Ruvo, Ewan Tempero, Andrew Luxton-Reilly, Gerard B Rowe, and Nasser Giacaman. 2018. Understanding semantic style by analysing student code. In ACE.Google Scholar
- Stephen H Edwards, Nischel Kandru, and Mukund BM Rajagopal. 2017. Investigating static analysis errors in student Java programs. In ICER.Google Scholar
- Tomá? Effenberger and Radek Pelánek. 2022. Code Quality Defects across Introductory Programming Topics. In SIGCSE.Google Scholar
- Martin Fowler. 2018. Refactoring: improving the design of existing code.Google Scholar
- Luke Gusukuma, Austin Cory Bart, Dennis Kafura, and Jeremy Ernst. 2018. Misconception-driven feedback: Results from an experimental study. In ICER.Google Scholar
- Paul Richard Halmos. 1960. Naive set theory. van Nostrand.Google Scholar
- Geoffrey L Herman, Michael C Loui, Lisa Kaczmarczyk, and Craig Zilles. 2012. Describing the what and why of students' difficulties in Boolean logic. Transactions on Computing Education (2012).Google Scholar
- Maria Hristova, Ananya Misra, Megan Rutter, and Rebecca Mercuri. 2003. Identifying and correcting Java programming errors for introductory computer science students. SIGCSE (2003).Google Scholar
- Christopher Hundhausen, Anukrati Agrawal, Dana Fairbrother, and Michael Trevisan. 2009. Integrating pedagogical code reviews into a CS 1 course: an empirical study. SIGCSE (2009).Google ScholarDigital Library
- Cruz Izu, Paul Denny, and Sayoni Roy. 2022. A Resource to Support Novices Refactoring Conditional Statements. In ITiCSE.Google Scholar
- Bernard J Jansen. 2006. Search log analysis: What it is, what's been done, how to do it. Library & information science research (2006).Google Scholar
- Hieke Keuning, Bastiaan Heeren, and Johan Jeuring. 2017. Code quality issues in student programs. In ITiCSE.Google Scholar
- Hieke Keuning, Bastiaan Heeren, and Johan Jeuring. 2020. Student refactoring behaviour in a programming tutor. In Koli Calling.Google Scholar
- Hieke Keuning, Bastiaan Heeren, and Johan Jeuring. 2021. A tutoring system to learn code refactoring. In SIGCSE.Google Scholar
- Diana Kirk, Tyne Crow, Andrew Luxton-Reilly, and Ewan Tempero. 2020. On assuring learning about code quality. In ACE.Google Scholar
- Essi Lahtinen, Kirsti Ala-Mutka, and Hannu-Matti Järvinen. 2005. A study of the difficulties of novice programmers. SIGCSE (2005).Google Scholar
- Andrew Luxton-Reilly, Paul Denny, Diana Kirk, Ewan Tempero, and Se-Young Yu. 2013. On the differences between correct student solutions. In ITiCSE.Google Scholar
- Steve McConnell. 2004. Code complete.Google Scholar
- Ioana T Mow. 2008. Issues and difficulties in teaching novice computer programming. In Innovative Techniques in Instruction Technology, E-learning, E-assessment and Education.Google Scholar
- Sebastian C Müller and Thomas Fritz. 2016. Using (bio) metrics to predict code quality online. In ICSE.Google Scholar
- Yizhou Qian and James Lehman. 2017. Students' misconceptions and other difficulties in introductory programming: A literature review. Transactions on Computing Education (2017).Google Scholar
- Teemu Sirkiä and Juha Sorva. 2012. Exploring programming misconceptions: an analysis of student mistakes in visual program simulation exercises. In Koli Calling.Google Scholar
- John P Smith III, Andrea A DiSessa, and Jeremy Roschelle. 1994. Misconceptions reconceived: A constructivist analysis of knowledge in transition. The journal of the learning sciences (1994).Google Scholar
- Juha Sorva. 2013. Notional Machines and Introductory Programming Education. Transactions on Computing Education (2013).Google Scholar
- Martijn Stegeman, Erik Barendsen, and Sjaak Smetsers. 2016. Designing a rubric for feedback on code quality in programming courses. In Koli Calling.Google Scholar
- Anselm Strauss and Juliet Corbin. 1990. Basics of qualitative research.Google Scholar
- Leo C Ureel II and Charles Wallace. 2019. Automated critique of early programming antipatterns. In SIGCSE.Google Scholar
- Kurt VanLehn. 1982. Bugs are not enough: Empirical studies of bugs, impasses and repairs in procedural skills. The Journal of Mathematical Behavior (1982).Google Scholar
- Eliane S Wiese, Anna N Rafferty, Daniel M Kopta, and Jacqulyn M Anderson. 2019. Replicating novices' struggles with coding style. In ICPC.Google Scholar
- Eliane S Wiese, Michael Yen, Antares Chen, Lucas A Santos, and Armando Fox. 2017. Teaching students to recognize and implement good coding style. In L@S.Google Scholar
Index Terms
- Student Code Refactoring Misconceptions
Recommendations
Investigating Student Errors in Code Refactoring
ITiCSE 2023: Proceedings of the 2023 Conference on Innovation and Technology in Computer Science Education V. 2Learning to develop code of good quality is challenging. One way to improve code quality is through code refactoring. Students make several mistakes when refactoring code. This research project aims to comprehend student errors in code refactoring, as ...
Toward proactive refactoring: an exploratory study on decaying modules
IWOR '19: Proceedings of the 3rd International Workshop on RefactoringSource code quality is often measured using code smell, which is an indicator of design flaw or problem in the source code. Code smells can be detected using tools such as static analyzer that detects code smells based on source code metrics. Further, ...
University Code Refactoring Practice-Driven Curriculum Instructed by Industry Professionals
CompEd '19: Proceedings of the ACM Conference on Global Computing EducationAs software design and development is engineering technology and art, the design and coding capabilities of software engineers require continuous development and practice. After learning the basic concepts of computers, students need to constantly ...
Comments