Sample
JetBrains/b46
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0 | 0–1; higher is more readable | 60.2Δ 10.2 |
| Scalabrino | 0.422 | 0–1; higher is more readable | 25.8Δ 44.5 |
| Dorn | 0.647 | 0–1; higher is more readable | 76.3Δ 5.9 |
| Mi | 0.678 | 0–1; higher is more readable | 94.1Δ 23.7 |
| LLOC | 15 | Logical lines; fewer is more readable | 43.6Δ 26.7 |
| DeepSeek V4 Pro | 16.67 | 0–20; mean of three runs | 62.3Δ 8.1 |
| GPT-6.1 Sol | 18 | 0–20; mean of three runs | 77.5Δ 7.2 |
| BTTF | 0.451 | 0–1; higher is more readable | 44.9Δ 25.4 |
| Human | 0.85 | 0–1; original rating | 70.3 |
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. | 682.429 | −22.52 |
| Source linesThe number of non-empty source lines. | 24 | +9.6 |
| 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.503 | −5.255 |
Intercept 8.87 + feature contributions = -9.305 (log-odds).
Score = sigmoid(-9.305) = 0.
| Score | 0.422 |
|---|
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. | 45.958 | +1.719 |
| 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 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 1 | −0.703 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.144 | −0.459 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 24 | −0.13 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 22.851 | −0.09 |
Intercept 0.07 + feature contributions = 0.604 (log-odds).
Score = sigmoid(0.604) = 0.647.
| Score | 0.678 |
|---|
| Score | 15 |
|---|
Run 1
The code is well-structured with clear separation of concerns. Each divisibility check is a flat, independent if-statement, avoiding deep nesting. Variable names like 'output' clearly indicate intent. The logic flows naturally from checking conditions to printing the result. While the code is somewhat verbose for the problem it solves, the repetition actually aids readability by making the pattern obvious. Each line performs a single action, and the if-else at the end handles the two distinct output cases clearly. Minor improvements could include extracting the divisibility checks or using a StringBuilder, but overall the code is very readable and maintainable.
Run 2
The code is well-structured and readable. It uses a flat, linear control flow with no nested conditionals beyond the main loop. The intent is clear: generate a modified FizzBuzz-style output for numbers 1–1000. Each conditional check is independent and easy to follow. Action granularity is generally good—each `if` performs a single append, and printing is separated into a clear if/else. The only minor drawbacks are the verbose empty-string check (`output.equals("")`) and some repetition in the conditional blocks, which could be simplified with a helper method or array of divisors. Overall, the code is concise, predictable, and easy to scan.
Run 3
The code is well-structured, using a simple, single-level loop with separate, flat if statements for each divisor. Each condition performs one clear, logical action—appending a word to the output string—and the final conditional handles printing concisely. Intent is obvious: a FizzBuzz variant. Nesting is minimal, and the flow follows a natural sequence: build output, then decide what to print. Code length is reasonable, though the empty string check (output.equals("")) could be slightly optimized to output.isEmpty(), and the repeated System.out.println could be simplified to a single print after determining the final result. Overall, it's clean, readable, and maintainable, but minor refinements could improve elegance.
Run 1
Code Structure: A single loop with independent divisibility checks is logically organized. Nesting: Shallow, consistent nesting makes the control flow easy to follow. Clarity of intent: The code clearly prints concatenated labels for matching divisors, otherwise the number; named constants could better explain the range and divisor-label mappings. Code length: Concise for its purpose, though the repeated checks introduce minor duplication. Action granularity: Each statement performs one clear action. Reading flow: Initialization, label construction, and output appear in a natural sequence. Using output.isEmpty() rather than output.equals("") would express the empty-string check more directly.
Run 2
Code Structure: Logically organized into a single loop with sequential divisibility checks and a final output decision. Nesting: Shallow and consistent; conditionals sit directly inside the loop. Clarity of intent: The number-to-label mapping is easy to understand, though the loop bound and label choices lack explanatory context. Code length: Concise for its purpose, with minor repetition that remains easy to follow. Action granularity: Each assignment, check, and print occupies its own line; the conventional for-loop header is clear. Reading flow: Natural progression from initializing the output to appending matching labels and printing either the result or the number. Using output.isEmpty() instead of output.equals("") would slightly improve idiomatic readability.
Run 3
Code Structure: Logically organized around a loop, divisibility checks, and output selection. Nesting: Shallow and consistent, with no deeply nested conditionals. Clarity of intent: The independent checks clearly build a combined label for each number, although the significance of the labels and upper limit is unexplained. Code length: Concise; the repeated checks are straightforward rather than unnecessarily verbose. Action granularity: Each statement performs one clear action, with conventional loop syntax. Reading flow: Natural top-to-bottom progression from initialization through label construction to printing. Minor improvements include using output.isEmpty() instead of output.equals("") and naming the upper limit if it has domain significance.