FAILURE MAP
← Case archive

FA-97743 / Knitting and sewing pattern grading / Member archive

Knitting needle size converter: tie-break toward larger · case 03

5.75 mm converts to US 9 instead of US 10.

Member previewVariant 3 · 3 implementations · 8 checks per implementation

Case contract

Table US->mm: 0 2.0, 1 2.25, 2 2.75, 3 3.25, 4 3.5, 5 3.75, 6 4.0, 7 4.5, 8 5.0, 9 5.5, 10 6.0, 10.5 6.5, 11 8.0, 13 9.0, 15 10.0. "us->mm": trim, "10 1/2" means "10.5", exact match or "error: size". "mm->us": nearest size within 0.5 mm inclusive, ties to the larger mm, else "error: size". Other directions -> "error: direction".

Why this case matters

Patterns list needle sizes in US or metric and knitters convert between them.

One recorded failure

Sample boundary fixture

This sample comes from the broken implementation of a controlled reproducer.

Boundary fixtureActualExpectedOutcome
tie between 9 and 10"9""10"Failed

MEMBER ARCHIVE

The complete case is available to members.

This record includes three runnable implementations, regression fixtures, execution results, and source hashes.

Member access is invitation-based. Sign in with your invited account to inspect the sources.

Sign in to the archive ↗