← 6c2353a2cdee · 6c5bf76aa982 →
6c40e60caa4a
Fill the interior of the deepest color-1 frame around each color-2 seed.
parametric familyconditional fillhierarchy resolutionnested containment
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* ((frames
(filter
(lambda (obj)
(let* ((bb (obj-bbox obj))
(r0 (first bb))
(c0 (second bb))
(r1 (third bb))
(c1 (fourth bb)))
(and (= (obj-color obj) 1)
(all?
(lambda (p)
(let ((r (fst p)) (c (snd p)))
(= (cell-at g r c) 1)))
(filter
(lambda (p)
(let ((r (fst p)) (c (snd p)))
(or (= r r0) (= r r1) (= c c0) (= c c1))))
(positions-in-rect r0 c0 r1 c1))))))
(objects g 0)))
(seeded
(filter
(lambda (obj)
(let* ((bb (obj-bbox obj))
(r0 (first bb))
(c0 (second bb))
(r1 (third bb))
(c1 (fourth bb)))
(any?
(lambda (p) (= (cell-at g (fst p) (snd p)) 2))
(positions-in-rect (+ r0 1) (+ c0 1) (- r1 1) (- c1 1)))))
frames))
(deepest
(filter
(lambda (obj)
(let* ((bb (obj-bbox obj))
(r0 (first bb))
(c0 (second bb))
(r1 (third bb))
(c1 (fourth bb)))
(not
(any?
(lambda (other)
(let* ((ob (obj-bbox other))
(or0 (first ob))
(oc0 (second ob))
(or1 (third ob))
(oc1 (fourth ob)))
(and (not (and (= r0 or0) (= c0 oc0) (= r1 or1) (= c1 oc1)))
(> or0 r0) (< or1 r1)
(> oc0 c0) (< oc1 c1))))
seeded))))
seeded)))
(grid-from-fn h w
(lambda (r c)
(if (any?
(lambda (obj)
(let ((bb (obj-bbox obj)))
(and (> r (first bb)) (< r (third bb))
(> c (second bb)) (< c (fourth bb)))))
deepest)
3
(cell-at g r c))))))Provenance
- Generator
- generators/6c40e60caa4a/generator.py
- Notes and decisions
- generators/6c40e60caa4a/notes.md
- Review label
- reviewed_safe
- Generator SHA-256
- c3ef815111e2bfd816c98552ba722680fa525cb4386be9640ff1c20d324924cb
- Rule hash
- e82c2d54609b
- Sources
- bank:e352836528da
- Lesson seeds
- 20261108, 20261109, 20261110, 20261111, 20261112
- Reproduce lesson 1
arcpuzzles generate 6c40e60caa4a --count 1 --seed 20261108 --test 1