← 7fd453cd0339 · 80271cb9b303 →

7fe59337a0b4

Crop the sole nonzero, non-9 motif. On a fresh black canvas, place the original immediately above the color-9 marker, then its 90-degree clockwise, 180-degree, and 270-degree rotations to the right, below, and left; retain the marker.

parametric familycenteringobject_reasoningrelayoutrotation

Generated by the released generator before publication; every output was computed by its Racket reference rule. White outlines mark the cells the rule changed. Lesson check:

refuted: a demonstration contradicts the rival. survived_all: it fits every demonstration and also gives the intended answer, so it cannot mislead here. ambiguous: it fits every demonstration but answers the query differently. Names are as declared by the generator; a declared shortcut is not guaranteed to fit the original pairs (see the paper’s Limitations).

Original task pairs

From the source task; the reference rule must reproduce them.

Reference rule (Racket)

(rule! (let ((dummy 0)) (define (crop-nonzero grid) (let ((cells (filter (lambda (p) (not (= (at grid (first p) (second p)) 0))) (grid-positions grid)))) (if (empty? cells) (list (list 0)) (let* ((bb (bbox-of-cells cells)) (r0 (first bb)) (c0 (second bb)) (r1 (third bb)) (c1 (fourth bb))) (subgrid grid r0 c0 r1 c1))))) (define (paste-crop grid shape top left) (for*/fold ((out grid)) ((r (in-range (rows shape))) (c (in-range (cols shape)))) (let ((v (at shape r c)) (rr (+ top r)) (cc (+ left c))) (if (and (not (= v 0)) (in-bounds? rr cc (rows grid) (cols grid))) (set-cell out rr cc v) out)))) (let* ((center (first (find-color g 9))) (ch (first center)) (cw (second center)) (obj-grid (grid-from-fn (rows g) (cols g) (lambda (r c) (let ((v (at g r c))) (if (and (not (= v 0)) (not (= v 9))) v 0))))) (shape (crop-nonzero obj-grid)) (r0 shape) (r1 (rotate-cw r0)) (r2 (rotate-cw r1)) (r3 (rotate-cw r2)) (a (paste-crop (empty-grid (rows g) (cols g) 0) r0 (- ch 1 (rows r0)) (- cw (quotient (cols r0) 2)))) (b (paste-crop a r1 (- ch (quotient (rows r1) 2)) (+ cw 2))) (c (paste-crop b r2 (+ ch 2) (- cw (quotient (cols r2) 2)))) (d (paste-crop c r3 (- ch (quotient (rows r3) 2)) (- cw 1 (cols r3))))) (set-cell d ch cw 9))))

Provenance

Generator
generators/7fe59337a0b4/generator.py
Notes and decisions
generators/7fe59337a0b4/notes.md
Review label
reviewed_safe
Generator SHA-256
3b9c9ef989d5688979c834e636902d40e60622b7e19110d82eed60227c15c975
Rule hash
e5504f0fdce0
Sources
bank:e07509d599a1
Lesson seeds
20261108, 20261109, 20261110, 20261111, 20261112
Reproduce lesson 1
arcpuzzles generate 7fe59337a0b4 --count 1 --seed 20261108 --test 1