{"title":"A tool for measuring program comprehensibility using readability-driven metrics","authors":"Md. Masudur Rahman, Zenun Chowdhury, Raqeebir Rab","doi":"10.1016/j.simpa.2025.100782","DOIUrl":null,"url":null,"abstract":"<div><div>Program comprehensibility plays a significant role in software maintenance by enhancing code readability. Although inherently subjective, various methods to assess comprehensibility have emerged in recent years. Most of these approaches focus on structural characteristics of source code, such as lines of code, number of identifiers, cyclomatic complexity, etc. However, textual elements are equally vital, as these directly influence how humans interpret and understand code. In this paper, we present an approach that evaluates program comprehensibility based on the textual readability of source code — reflecting how it is perceived by human readers. We developed a tool to implement this proposed approach and validated its effectiveness by comparing its output with manual evaluations of code comprehensibility. The results showed complete agreement, indicating that the tool produces comprehensibility scores. This tool can support developers by identifying segments of code that are harder to comprehend, enabling targeted refactoring efforts to improve overall readability.</div></div>","PeriodicalId":29771,"journal":{"name":"Software Impacts","volume":"25 ","pages":"Article 100782"},"PeriodicalIF":1.2000,"publicationDate":"2025-07-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Software Impacts","FirstCategoryId":"1085","ListUrlMain":"https://www.sciencedirect.com/science/article/pii/S2665963825000429","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"Q3","JCRName":"COMPUTER SCIENCE, SOFTWARE ENGINEERING","Score":null,"Total":0}
引用次数: 0
Abstract
Program comprehensibility plays a significant role in software maintenance by enhancing code readability. Although inherently subjective, various methods to assess comprehensibility have emerged in recent years. Most of these approaches focus on structural characteristics of source code, such as lines of code, number of identifiers, cyclomatic complexity, etc. However, textual elements are equally vital, as these directly influence how humans interpret and understand code. In this paper, we present an approach that evaluates program comprehensibility based on the textual readability of source code — reflecting how it is perceived by human readers. We developed a tool to implement this proposed approach and validated its effectiveness by comparing its output with manual evaluations of code comprehensibility. The results showed complete agreement, indicating that the tool produces comprehensibility scores. This tool can support developers by identifying segments of code that are harder to comprehend, enabling targeted refactoring efforts to improve overall readability.