Sample
int-66a35450a031-I01
Remove line comments, block comments, and Javadoc
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.533 | 0–1; higher is more readable |
| Dorn | 0.724 | 0–1; higher is more readable |
| Mi | 0.165 | 0–1; higher is more readable |
| LLOC | 43 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 18 | 0–20; mean of three runs |
| GPT-6.1 Sol | 17 | 0–20; mean of three runs |
| BTTF | 0.434 | 0–1; higher is more readable |
Views
Loading feature diagnosis…
Source regions
Feature contributions
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 5186.14 | −171.143 |
| Source linesThe number of non-empty source lines. | 151 | +60.4 |
| Byte entropyHow varied the bytes in the source text are. Repeated bytes give a lower value; a more even mixture gives a higher value. | 4.854 | −7.281 |
Intercept 8.87 + feature contributions = -109.154 (log-odds).
Score = sigmoid(-109.154) = 0.
| Score | 0.533 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Indentation frequencyHow rapidly indentation changes from line to line. | 151 | +4.486 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 152 | −4.346 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 150.919 | +1.7 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 0 | −0.804 |
| Identifier layout (horizontal)How rapidly the visual pattern of identifier characters changes from left to right. It measures spatial frequency, not the meaning of the names. | 97.921 | −0.482 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.103 | −0.058 |
Intercept 0.07 + feature contributions = 0.963 (log-odds).
Score = sigmoid(0.963) = 0.724.
| Score | 0.165 |
|---|
| Score | 43 |
|---|
Run 1
The code is highly readable with clear structure and consistent formatting. It follows a logical organization: fields, constructor, abstract methods, private helpers, then grouped public methods. Nesting is minimal—only a lambda inside wrapTask. Intent is explicit through descriptive method names and the delegation pattern. Code length is appropriate, avoiding unnecessary verbosity while maintaining clarity. Action granularity is excellent, with one logical operation per line. Reading flow is natural, with methods grouped by functionality (task execution, submission, invocation, lifecycle). The only minor deductions are for some redundant javadoc comments and the somewhat dense generic type declarations.
Run 2
This code is highly readable due to its clear, logical structure and consistent delegation pattern. The class is organized into distinct sections for abstract methods, helper methods, task submission, and lifecycle management, making the purpose of each method obvious. Nesting is minimal, with only one small try-catch block in the Runnable wrapper. The intent is explicit: wrap tasks before delegating to an underlying ExecutorService. Action granularity is excellent, with each method performing a single, clear action. The code is concise without sacrificing clarity, avoiding unnecessary verbosity. Reading flows naturally from constructor to abstract methods, to helper methods, then through the ExecutorService interface implementations. Generics and nullness annotations add some visual complexity, but this is expected for a Guava utility class and does not impede comprehension for experienced Java developers.
Run 3
The code is highly readable due to its clear structure and logical organization. It follows the Wrapper/Decorator pattern, with the delegate executor clearly separated and all methods delegating consistently. Nesting is minimal, with only one level inside the wrapTask method for handling exceptions. Each public method has a single purpose, and operations are generally one action per line, enhancing clarity. The intent is obvious: wrapping task submissions while preserving ExecutorService behavior. Naming is descriptive, and the use of final methods and fields reinforces immutability and thread-safety expectations. Comments are concise and informative, particularly those explaining non-obvious exception handling. The only minor readability drawbacks are the generic type declarations, which add some verbosity, and the multiple blank lines before the class declaration, which appear unintentional. Overall, the code is clean, maintains flat structure, and reads naturally from constructor through task-wrapping methods to delegation and shutdown operations.
Run 1
Code Structure: Logically organized into task-wrapping helpers, execution methods, and lifecycle delegation. Nesting: Shallow overall; only the Runnable adapter introduces a lambda with try/catch. Clarity of intent: Descriptive names and consistent delegation clearly communicate the wrapper pattern, though undocumented exception handling and nullness annotations add complexity. Code length: Methods are concise, and repetition largely follows the ExecutorService interface; excessive blank lines unnecessarily inflate the presentation. Action granularity: Statements generally perform one action each, with short nested calls remaining easy to understand. Reading flow: Predictable method grouping and consistent formatting support natural reading, but irregular whitespace interrupts continuity.
Run 2
Code Structure: Well organized into task-wrapping helpers, execution methods, and lifecycle delegation. Nesting: Mostly flat; the Runnable wrapper adds modest lambda and try/catch nesting. Clarity of intent: Descriptive names and consistent delegation make the wrapping purpose clear, although the abstract wrapping contract and exception handling lack explanatory documentation. Code length: Methods are concise, and most repetition is justified by the ExecutorService interface; excessive blank lines unnecessarily expand the listing. Action granularity: Statements generally perform one clear action, with straightforward nested calls for wrapping and delegation. Reading flow: Consistent formatting and sensible method grouping support natural reading, but irregular whitespace and verbose generic annotations slightly interrupt the flow.
Run 3
Code Structure: Well organized into task-wrapping helpers, execution methods, and lifecycle delegation. Nesting: Mostly flat; only the Runnable adapter introduces a lambda with try/catch. Clarity of intent: Descriptive names and consistent delegation clearly communicate the wrapper's purpose, though exception conversion and nullness annotations require some Java familiarity. Code length: Methods are concise, and repeated delegation is justified by the interface; excessive blank lines unnecessarily expand the listing. Action granularity: Statements generally perform one logical action per line, with straightforward nested calls for wrapping and validation. Reading flow: Consistent formatting and method grouping support natural reading, but irregular whitespace and long generic signatures mildly disrupt it.