Each digital digit resides in an indexed 7-slot matrix. In our procedural engine, these segments are tracked as binary flags from index 0 to index 6:
── 0 ──
│ │
1 2
│ │
── 3 ──
│ │
4 5
│ │
── 6 ──
Index Mapping:
0: Top 1: Top-Left 2: Top-Right
3: Middle 4: Bottom-Left 5: Bottom-Right
6: Bottom
A bitmask integer is formed by shifting active segments. When a stick is moved, the solver verifies the updated bitmask against our static lookup table (DIGIT_BY_CODE). If the resulting pattern does not correspond to a valid digit between 0 and 9, the move is rejected.