Sample
JetBrains/i34
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0.002 | 0–1; higher is more readable | 76.3Δ 14.8 |
| Scalabrino | 0.689 | 0–1; higher is more readable | 54.2Δ 7.2 |
| Dorn | 0.741 | 0–1; higher is more readable | 92.4Δ 30.9 |
| Mi | 0.586 | 0–1; higher is more readable | 70.3Δ 8.9 |
| LLOC | 10 | Logical lines; fewer is more readable | 72.9Δ 11.4 |
| DeepSeek V4 Pro | 13.33 | 0–20; mean of three runs | 28.0Δ 33.5 |
| GPT-6.1 Sol | 15.33 | 0–20; mean of three runs | 17.8Δ 43.6 |
| BTTF | 0.55 | 0–1; higher is more readable | 78.8Δ 17.4 |
| Human | 0.8 | 0–1; original rating | 61.4 |
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. | 517.969 | −17.093 |
| Source linesThe number of non-empty source lines. | 18 | +7.2 |
| Byte entropyHow varied the bytes in the source text are. Repeated bytes give a lower value; a more even mixture gives a higher value. | 3.395 | −5.093 |
Intercept 8.87 + feature contributions = -6.116 (log-odds).
Score = sigmoid(-6.116) = 0.002.
| Score | 0.689 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| 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. | 58 | +1.209 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 1 | +1.001 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 0 | −0.804 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 16.831 | −0.175 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.112 | −0.144 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 18 | −0.115 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 18 | +0.008 |
Intercept 0.07 + feature contributions = 1.05 (log-odds).
Score = sigmoid(1.05) = 0.741.
| Score | 0.586 |
|---|
| Score | 10 |
|---|
Run 1
The code is structured logically with a clear main method and a simple loop. However, nesting is deeper than necessary due to the three-level if/else chain for the leap year rule. The purpose is understandable, but adding a comment would improve intent clarity. The code is concise but could be shorter by combining the conditions. Action granularity is one action per line, which is good. The reading flow is mostly natural, but the nested conditionals require extra effort to follow. Overall, it's readable but could be improved by flattening the logic into a single boolean expression.
Run 2
The code has a clear overall purpose: print leap years in a range. Structure is simple, but the leap year logic is implemented with three nested if statements, which increases nesting and reduces readability. Although each condition is on its own line, the repeated print statement and embedded logic make the intent somewhat harder to grasp at a glance. The approach is concise but not the most elegant; a combined boolean expression would flatten the nesting and better express the leap year rule. Variable names are clear, and the loop is straightforward, but the nesting and duplication weaken clarity and reading flow.
Run 3
The code is logically organized and fairly readable, but it has some structural issues. It uses nested `if` statements for leap year logic, which creates three levels of nesting and makes the logic less clear than it could be. The intent is understandable—printing leap years in a range—but the logic could be simplified for better clarity. The code is concise and each action is on its own line, aiding readability. However, the reading flow is slightly disrupted by the nested structure and the duplicated `System.out.print` statement. The class and variable names are clear. Overall, it is readable but could be improved by flattening the nesting (e.g., using logical operators) and reducing duplication.
Run 1
Code Structure: Logically organized, with range initialization followed by iteration and leap-year checks. Nesting: Three nested conditionals inside the loop add avoidable complexity; a combined boolean condition would be flatter. Clarity of intent: The class name, variable names, and divisibility checks make the purpose clear. Code length: Short overall, but duplicated print statements and nested branches make it longer than necessary. Action granularity: Each statement performs a single action; the loop header uses conventional initialization, condition, and increment. Reading flow: Execution proceeds naturally, though inconsistent spacing and the separated else placement slightly hinder scanning.
Run 2
Code Structure: Logically organized into initialization, iteration, leap-year checks, and output. Nesting: Three nested conditionals inside the loop add avoidable complexity; a combined boolean condition would be flatter. Clarity of intent: The class name and descriptive year variables clearly communicate the purpose, while the divisibility checks express the leap-year rules. Code length: Short overall, though the duplicated print statement and nested branches could be simplified. Action granularity: Statements generally perform one action per line; the loop header follows standard Java conventions. Reading flow: Execution proceeds naturally, but inconsistent spacing and the separated else placement slightly disrupt scanning.
Run 3
Code Structure: Logically organized around a year range, loop, and leap-year checks. Nesting: Three nested conditionals inside the loop add unnecessary depth; a single combined condition would be easier to scan. Clarity of intent: The class name and descriptive variables clearly convey the purpose, although the leap-year rule requires tracing branches. Code length: Short overall, but duplicated print statements and nested branches could be consolidated. Action granularity: Each statement performs one clear action; the standard for-loop header is appropriate. Reading flow: Execution proceeds naturally from setup to iteration and output, but inconsistent spacing and the separated else placement slightly interrupt scanning.