[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"doc-detail-116838-en":3,"doc-seo-116838-105":30,"detail-sidebar-cat-0-en-105":92},{"code":4,"msg":5,"data":6},0,"success",{"doc_id":7,"user_id":8,"nickname":9,"user_avatar":10,"doc_module":4,"category_id":11,"category_name":12,"doc_title":13,"doc_description":14,"doc_content":15,"file_id":16,"file_url":17,"file_type":18,"file_size":19,"view_count":20,"is_deleted":4,"is_public":20,"is_downloadable":20,"audit_status":20,"page_count":21,"language":22,"language_code":23,"site_id":24,"html_lang":23,"table_of_contents":25,"faqs":26,"seo_title":27,"seo_description":14,"update_tm":28,"read_time":29},116838,1099513958607,"Jiven","https://ap-avatar.wpscdn.com/avatar/100002390cf8733938c?x-image-process=image/resize,m_fixed,w_180,h_180&k=1778829742770036399",8,"Research & Report","Investigating Novice Developers' Code Commenting Trends Using Machine Learning Techniques","Code comments improve the ability to understand and read software by explaining what a code block does and why it matters. Because of this, novice developers need targeted support to strengthen their commenting skills. This study analyzes the comment types that novice students produce, then applies a machine learning workflow to categorize their source code comments automatically. Results identify Literal and Insufficient as dominant categories, expand the taxonomy with additional labels, and show Decision Tree reaching about 85% overall accuracy.","algorithms  \nArticle  \nInvestigating Novice Developers' Code Commenting Trends Using Machine Learning Techniques  \nTahira Niazi 1, Teerath Das 2, Ghufran Ahmed 3, Syed Muhammad Waqas 4, Sumra Khan 1, Suleman Khan 5,*, Ahmed Abdelaziz Abdelatif 6 and Shaukat Wasi 1  \nCitation: Niazi, T.; Das, T.;  \nAhmed, G.; Waqas, S.M.; Khan, S.; Khan, S.; Abdelatif, A.A.; Wasi, S. Investigating Novice Developers'Code Commenting Trends Using Machine Learning Techniques. Algorithms 2023, 16, 53. [https://](https://)[ ](https://)[doi.org/10.3390/a16010053](doi.org/10.3390/a16010053)  \nAcademic Editors: Xiang Zhang and Xiaoxiao Li  \nReceived: 12 October 2022  \nRevised: 2 January 2023  \nAccepted: 4 January 2023  \nPublished: 12 January 2023  \nCopyright: © 2023 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license ([https://](https://)[ ](https://)[creativecommons.org/licenses/by/](creativecommons.org/licenses/by/)[ ](creativecommons.org/licenses/by/)[4.0/](4.0/)) .  \n1 Department of Computer Science, Mohammad Ali Jinnah University, Karachi 75400, Pakistan  \n2 Faculty of Information Technology, University of Jyväskylä, 40014 Jyväskylä, Finland  \n3 School of Computing, National University of Computer Emerging Sciences, Karachi 75400, Pakistan  \n4 Department of Computer Science, Bahria University, Karachi 75260, Pakistan  \n5 School of Psychology and Computer Science, University of Central Lancashire, Preston PR1 2HE, UK  \n6 Khawarizmi International College, Al Bahya, Abu Dhabi 25669, United Arab Emirates  \n* Correspondence: [skhan92@uclan.ac.uk](skhan92@uclan.ac.uk)  \nAbstract: Code comments are considered an efﬁcient way to document the functionality of a particular block of code. Code commenting is a common practice among developers to explain the purpose of the code in order to improve code comprehension and readability. Researchers investigated the effect of code comments on software development tasks and demonstrated the use of comments in several ways, including maintenance, reusability, bug detection, etc. Given the importance of code comments, it becomes vital for novice developers to brush up on their code commenting skills. In this study, we initially investigated what types of comments novice students document in their source code and further categorized those comments using a machine learning approach. The work involves the initial manual classiﬁcation of code comments and then building a machine learning model to classify student code comments automatically. The ﬁndings of our study revealed that novice developers/students' comments are mainly related to Literal (26.66%) and Insufﬁcient (26.66%) . Further, we proposed and extended the taxonomy of such source code comments by adding a few more categories, i.e., License (5.18%), Proﬁle (4.80%), Irrelevant (4.80%), Commented Code (4.44%), Autogenerated (1.48%), and Improper (1.10%) . Moreover, we assessed our approach with three different machine-learning classiﬁers. Our implementation of machine learning models found that Decision Tree resulted in the overall highest accuracy, i.e., 85% . This study helps in predicting the type of code comments for a novice developer using a machine learning approach that can be implemented to generate automated feedback for students, thus saving teachers time for manual one-on-one feedback, which is a time-consuming activity.  \nKeywords: source code comments; classiﬁcation; machine learning techniques  \n1. Introduction  \nCode comments are considered an integral and indispensable activity across various tasks in the software development life cycle (SDLC) . Indeed, it is necessary for the developers and peer reviewers to understand what the code is intended to perform and how it works. In recent times, with the increase in software complexity and the number of developers working on a single project, it has become necessary to wr","cbCaie1LxRAFKHKy","https://ap.wps.com/l/cbCaie1LxRAFKHKy","pdf",2894831,1,19,"English","en",105,"# Introduction\n## Code conventions and the role of comments\n# Related background\n# Methodology\n## Manual classification and machine learning model building\n## Evaluation with multiple classifiers\n# Results and discussion\n## Category findings and taxonomy extension\n# Conclusion","[{\"question\":\"Why are code comments important for developers and peer reviewers?\",\"answer\":\"Code comments help developers and reviewers understand the intended behavior and how code works, especially as software complexity and team size increase.\"},{\"question\":\"How does the study categorize comments written by novice developers?\",\"answer\":\"The workflow starts with manual classification of novice students’ source code comments, then trains machine learning models to classify comment types automatically.\"},{\"question\":\"Which machine-learning classifier achieved the highest accuracy, and what accuracy was reported?\",\"answer\":\"The Decision Tree classifier produced the highest overall accuracy, reported at about 85%.\"}]","Investigating Novice Developers' Code Commenting Trends Using Machine Learning Techniques | PDF",1785672019,48,{"code":4,"msg":31,"data":32},"ok",{"site_id":24,"language":23,"slug":33,"title":13,"keywords":34,"description":14,"schema_data":35,"social_meta":87,"head_meta":89,"extra_data":91,"updated_unix":28},"investigating-novice-developers-code-commenting-trends-using-machine-learning-techniques","",{"@graph":36,"@context":86},[37,54,69],{"@type":38,"itemListElement":39},"BreadcrumbList",[40,44,48,51],{"item":41,"name":42,"@type":43,"position":20},"https://docshare.wps.com","Home","ListItem",{"item":45,"name":46,"@type":43,"position":47},"https://docshare.wps.com/document/","Document",2,{"item":49,"name":12,"@type":43,"position":50},"https://docshare.wps.com/document/research-report/",3,{"item":52,"name":13,"@type":43,"position":53},"https://docshare.wps.com/document/investigating-novice-developers-code-commenting-trends-using-machine-learning-techniques/116838/",4,{"url":52,"name":13,"@type":55,"author":56,"headline":13,"publisher":58,"fileFormat":61,"inLanguage":23,"description":14,"dateModified":62,"datePublished":63,"encodingFormat":61,"isAccessibleForFree":64,"interactionStatistic":65},"DigitalDocument",{"name":9,"@type":57},"Person",{"url":41,"name":59,"@type":60},"DocShare","Organization","application/pdf","2026-08-05","2026-08-02",true,{"@type":66,"interactionType":67,"userInteractionCount":20},"InteractionCounter",{"@type":68},"ViewAction",{"@type":70,"mainEntity":71},"FAQPage",[72,78,82],{"name":73,"@type":74,"acceptedAnswer":75},"Why are code comments important for developers and peer reviewers?","Question",{"text":76,"@type":77},"Code comments help developers and reviewers understand the intended behavior and how code works, especially as software complexity and team size increase.","Answer",{"name":79,"@type":74,"acceptedAnswer":80},"How does the study categorize comments written by novice developers?",{"text":81,"@type":77},"The workflow starts with manual classification of novice students’ source code comments, then trains machine learning models to classify comment types automatically.",{"name":83,"@type":74,"acceptedAnswer":84},"Which machine-learning classifier achieved the highest accuracy, and what accuracy was reported?",{"text":85,"@type":77},"The Decision Tree classifier produced the highest overall accuracy, reported at about 85%.","https://schema.org",{"og:url":52,"og:type":88,"og:title":13,"og:site_name":59,"og:description":14},"article",{"robots":90,"canonical":52},"index,follow",{"doc_id":7,"site_id":24},{"code":4,"msg":5,"data":93},[94,98,102,106,111,116,121,124,129,132,136],{"id":20,"doc_module":4,"doc_module_name":46,"category_name":95,"show_sort_weight":96,"slug":97},"Story & Novel",90,"story-novel",{"id":47,"doc_module":4,"doc_module_name":46,"category_name":99,"show_sort_weight":100,"slug":101},"Literature",80,"literature",{"id":53,"doc_module":4,"doc_module_name":46,"category_name":103,"show_sort_weight":104,"slug":105},"Exam",70,"exam",{"id":107,"doc_module":4,"doc_module_name":46,"category_name":108,"show_sort_weight":109,"slug":110},5,"Comic",60,"comic",{"id":112,"doc_module":4,"doc_module_name":46,"category_name":113,"show_sort_weight":114,"slug":115},6,"Technology",50,"technology",{"id":117,"doc_module":4,"doc_module_name":46,"category_name":118,"show_sort_weight":119,"slug":120},7,"Healthcare",40,"healthcare",{"id":11,"doc_module":4,"doc_module_name":46,"category_name":12,"show_sort_weight":122,"slug":123},30,"research-report",{"id":125,"doc_module":4,"doc_module_name":46,"category_name":126,"show_sort_weight":127,"slug":128},9,"Religion & Spirituality",20,"religion-spirituality",{"id":127,"doc_module":4,"doc_module_name":46,"category_name":130,"show_sort_weight":127,"slug":131},"World Cup","world-cup",{"id":133,"doc_module":4,"doc_module_name":46,"category_name":134,"show_sort_weight":133,"slug":135},10,"Lifestyle","lifestyle",{"id":21,"doc_module":4,"doc_module_name":46,"category_name":137,"show_sort_weight":107,"slug":138},"General","general"]