Sample
JetBrains/b64
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0 | 0–1; higher is more readable | 53.4Δ 27.1 |
| Scalabrino | 0.324 | 0–1; higher is more readable | 15.3Δ 11.0 |
| Dorn | 0.738 | 0–1; higher is more readable | 91.5Δ 65.3 |
| Mi | 0.47 | 0–1; higher is more readable | 46.6Δ 20.3 |
| LLOC | 18 | Logical lines; fewer is more readable | 29.7Δ 3.4 |
| DeepSeek V4 Pro | 7.67 | 0–20; mean of three runs | 5.9Δ 20.3 |
| GPT-6.1 Sol | 14 | 0–20; mean of three runs | 10.2Δ 16.1 |
| BTTF | 0.446 | 0–1; higher is more readable | 39.8Δ 13.6 |
| Human | 0.58 | 0–1; original rating | 26.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. | 750.454 | −24.765 |
| 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.567 | −5.35 |
Intercept 8.87 + feature contributions = -11.645 (log-odds).
Score = sigmoid(-11.645) = 0.
| Score | 0.324 |
|---|
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. | 62 | +1.039 |
| 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 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.112 | −0.142 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 24 | −0.13 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 24 | +0.093 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 22.762 | −0.092 |
Intercept 0.07 + feature contributions = 1.035 (log-odds).
Score = sigmoid(1.035) = 0.738.
| Score | 0.47 |
|---|
| Score | 18 |
|---|
Run 1
The code lacks logical structure: the main method contains the entire algorithm with no separation into methods or classes for clarity. The while-loop contains a nested for-loop and an if-else that performs the same action in both branches (currentIndex++), making the nesting inefficient and confusing. The logic to compute the inventory sequence is ambiguous without explanation—variables like 'count' and 'sequence' have generic names that don't convey intent. The code is unnecessarily long for what it does, with redundant assignments (sequence[currentIndex] = count; followed by sequence[currentIndex] = 0; when count == 0). Multiple actions are crammed into some lines, while the reading flow jumps from input to processing to output with no sectioning. Overall, it is hard to follow, maintain, or verify.
Run 2
The code's purpose is unclear from its structure and naming (e.g., 'InventorySequence', 'sequence', 'currentIndex'). There is redundant logic, such as assigning count then re-assigning 0, and the if-else branches do the same thing—making the intent ambiguous. The logic is flat and only mildly nested, but the reading flow is disjointed: the main loop, inner count loop, and output loop are all in one method with no helper functions or comments. Action granularity is mostly one action per line, but some lines could be clearer. Length is acceptable for the task, but the variable names and control flow make it longer in comprehension than necessary. Overall, it is functional but poorly structured and difficult to read without additional context.
Run 3
The code has some positive aspects like consistent indentation and a clear main method, but it suffers from several readability issues. The algorithm's intent is unclear from variable names like 'sequence' and 'currentIndex' which don't reveal that this generates an inventory sequence. The while loop with duplicate currentIndex++ in both if/else branches and redundant count==0 check shows poor logical organization. The code mixes multiple actions within loop blocks and lacks modularization which could improve clarity. While nesting depth is acceptable, the implementation is unnecessarily convoluted for what should be a simple counting operation. Better naming, extracted methods, and cleaner loop conditions would significantly improve readability.
Run 1
Code Structure: Initialization, sequence generation, and output are logically organized, but the redundant if/else obscures a simple index increment. Nesting: The while/for/if combination introduces moderate nesting, though it remains manageable. Clarity of intent: Variable names convey basic roles, but the sequence rule is undocumented and repeated 1000 literals obscure the configurable size. Code length: Fairly concise, but assigning zero again and duplicating currentIndex++ unnecessarily extend the code. Action granularity: Each statement performs one action, making individual operations easy to follow. Reading flow: Execution proceeds naturally from setup to computation to printing; inconsistent brace usage and spacing slightly disrupt readability.
Run 2
Code Structure: Initialization, sequence generation, and output are logically ordered, though the redundant if/else weakens organization. Nesting: The while/for/if combination creates moderate nesting but remains manageable. Clarity of intent: Descriptive names help, but the sequence rule lacks explanation, and repeated literal 1000 obscures the configurable size. Code length: Mostly concise; assigning zero when count is already zero and duplicating currentIndex++ unnecessarily lengthen it. Action granularity: Each statement performs one action, making individual operations easy to follow. Reading flow: Execution proceeds naturally from setup to calculation to printing, but inconsistent spacing and omitted braces slightly disrupt readability.
Run 3
Code Structure: Initialization, sequence generation, and output are logically organized, but the redundant if/else obscures a simple index increment. Nesting: The while/for/if nesting is moderate and manageable, though unnecessary branching adds depth. Clarity of intent: Variable names communicate their roles, and the counting operation is understandable, but the sequence's purpose is undocumented and 1000 is repeated as a magic number. Code length: Fairly concise, but assigning zero when count is already zero and duplicating currentIndex++ unnecessarily lengthen it. Action granularity: Each statement performs one action, making individual steps easy to follow. Reading flow: Execution proceeds naturally from setup to calculation to printing, but inconsistent spacing and omitted braces slightly reduce scanability.