Sample
JetBrains/b11
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0.018 | 0–1; higher is more readable | 93.2Δ 61.0 |
| Scalabrino | 0.866 | 0–1; higher is more readable | 85.6Δ 53.4 |
| Dorn | 0.682 | 0–1; higher is more readable | 80.5Δ 48.3 |
| Mi | 0.643 | 0–1; higher is more readable | 83.1Δ 50.8 |
| LLOC | 10 | Logical lines; fewer is more readable | 72.9Δ 40.7 |
| DeepSeek V4 Pro | 16.67 | 0–20; mean of three runs | 62.3Δ 30.1 |
| GPT-6.1 Sol | 17 | 0–20; mean of three runs | 46.2Δ 14.0 |
| BTTF | 0.55 | 0–1; higher is more readable | 79.7Δ 47.5 |
| Human | 0.63 | 0–1; original rating | 32.2 |
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. | 435.989 | −14.388 |
| Source linesThe number of non-empty source lines. | 16 | +6.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. | 3.256 | −4.884 |
Intercept 8.87 + feature contributions = -4.001 (log-odds).
Score = sigmoid(-4.001) = 0.018.
| Score | 0.866 |
|---|
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. | 46.938 | +1.677 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 0 | −0.804 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 16 | +0.47 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.13 | −0.32 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 14.875 | −0.202 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 16 | −0.184 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 16 | +0.054 |
Intercept 0.07 + feature contributions = 0.761 (log-odds).
Score = sigmoid(0.761) = 0.682.
| Score | 0.643 |
|---|
| Score | 10 |
|---|
Run 1
The code is well-structured and readable. It uses clear variable names (i, j, sum) and follows a logical flow: iterate numbers, find divisors, sum them, and check abundance. Nesting is moderate (two loops plus an if), but remains understandable. Intent is clear despite the lack of comments—the algorithm for abundant numbers is evident. Code length is concise and appropriate for the task. Each line performs a single action, maintaining good action granularity. However, readability could improve slightly by extracting the divisor-sum logic into a method, which would reduce nesting and enhance clarity.
Run 2
The code is highly readable due to its simple structure and clear purpose. It uses a straightforward nested loop to identify abundant numbers up to 1000. Nesting is only two levels deep, which is acceptable and avoids confusion. Each line performs a single action, contributing to a natural top-down reading flow. The code is concise without sacrificing clarity; variable names like 'sum' and loop indices are conventional. The logic for finding divisors is easy to follow, and the final condition (sum > i) directly expresses the definition of an abundant number. Minor deductions are for lack of comments to explain the mathematical concept and slightly less descriptive variable names (i, j) that could be more meaningful, such as 'candidate' and 'divisor'.
Run 3
The code is straightforward and logically structured, with a clear outer loop and inner loop. Nesting is only two levels deep, which is acceptable. The intent is evident from the class and variable names, though a comment or helper method could improve clarity. The code is concise and each line generally performs one action, aiding readability. The reading flow is natural: initialize, compute divisors, compare, and print. Minor deductions: sum calculation logic could be extracted for clarity, and magic numbers like 1001 reduce explicitness, but overall it is quite readable.
Run 1
Code Structure: Logically organized, with divisor summation followed by the abundance check. Nesting: Two loops and an inner conditional create moderate nesting, but the short blocks remain easy to follow. Clarity of intent: The class name and sum comparison communicate the purpose, though descriptive variable names and a named upper bound would improve clarity. Code length: Concise, with no unnecessary statements. Action granularity: Each statement performs a single clear action. Reading flow: Consistent indentation and sequential logic make the code natural to read; extracting the abundance test into a named method could further clarify intent.
Run 2
Code Structure: Logically organized, with divisor summation followed by the abundance check for each number. Nesting: Moderate nesting from two loops and a conditional, but easy to follow in this short program. Clarity of intent: The class name and sum comparison convey the purpose, though descriptive variable names and a named upper limit would improve clarity. Code length: Concise without unnecessary code. Action granularity: Each statement performs a single clear action; loop headers use conventional syntax. Reading flow: Natural progression from iteration to calculation to output, supported by consistent indentation. Extracting the abundance test into a named method could make the main routine more expressive.
Run 3
Code Structure: Logically organized, calculating each number’s proper-divisor sum before printing abundant numbers. Nesting: Two loops and an inner conditional create moderate but manageable nesting. Clarity of intent: The class name communicates the purpose, though descriptive variable names and a named upper limit would improve clarity. Code length: Concise, with no unnecessary statements. Action granularity: Each statement performs one clear action; the loop headers follow standard Java conventions. Reading flow: Consistent indentation and straightforward control flow make the code easy to follow. Extracting the divisor-sum calculation into a named method could further improve readability.