← a4f0ea66fd65 · a51a8e285ce9 →

a4fb12580b3f

Find the unique color-1 anchor component and recolor every non-background component that edge-touches it to 4; preserve the anchor and all non-neighbors.

parametric familyanchor objectscomponent adjacencysame-size recolor

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 (adjacent? grid a b) (any? (lambda (p) (any? (lambda (d) (member (list (+ (first p) (first d)) (+ (second p) (second d))) (obj-cells b))) cardinal-deltas)) (obj-cells a))) (define (neighbors grid objs i) (filter (lambda (j) (and (not (= i j)) (adjacent? grid (list-ref objs i) (list-ref objs j)))) (range 0 (length objs)))) (define objs (objects g 0)) (for/fold ((out g)) ((i (in-range (length objs)))) (if (= (obj-color (list-ref objs i)) 1) (for/fold ((acc out)) ((j (in-list (neighbors g objs i)))) (paint-cells acc (obj-cells (list-ref objs j)) 4)) out))))

Provenance

Generator
generators/a4fb12580b3f/generator.py
Notes and decisions
generators/a4fb12580b3f/notes.md
Review label
reviewed_safe
Generator SHA-256
092404c86bda0113b7cc90d48808a117e894911fca0c7fe351feec73ac5a8cf2
Rule hash
c58ce5ec72e9
Sources
bank:3a1815be7c2e
Lesson seeds
20261108, 20261109, 20261110, 20261111, 20261112
Reproduce lesson 1
arcpuzzles generate a4fb12580b3f --count 1 --seed 20261108 --test 1