← cb439f1b5f4a · cbe60e2c4b18 →
cbd933916656
0-bg grid containing exactly THREE separated same-color components with strictly distinct cardinal perimeters. Rule: rank components by perimeter from smallest to largest, then recolor them 2, 4, and 8 respectively.
parametric familycomponentsperimeterranking
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 (bbox< a b) (cond ((not (= (obj-r1 a) (obj-r1 b))) (< (obj-r1 a) (obj-r1 b))) ((not (= (obj-c1 a) (obj-c1 b))) (< (obj-c1 a) (obj-c1 b))) ((not (= (obj-r2 a) (obj-r2 b))) (< (obj-r2 a) (obj-r2 b))) (else (< (obj-c2 a) (obj-c2 b))))) (define (component-perimeter obj) (let ((cells (obj-cells obj))) (for/sum ((p (in-list cells))) (count-where (lambda (d) (not (member (list (+ (first p) (first d)) (+ (second p) (second d))) cells))) cardinal-deltas)))) (define palette (list 2 4 8)) (define ranked (sort (objects g 0) (lambda (a b) (cond ((not (= (component-perimeter a) (component-perimeter b))) (< (component-perimeter a) (component-perimeter b))) ((not (= (obj-size a) (obj-size b))) (< (obj-size a) (obj-size b))) (else (bbox< a b)))))) (for/fold ((out (empty-grid (rows g) (cols g) 0))) ((obj (in-list ranked)) (i (in-naturals 0))) (paint-cells out (obj-cells obj) (list-ref palette i)))))
Provenance
- Generator
- generators/cbd933916656/generator.py
- Notes and decisions
- generators/cbd933916656/notes.md
- Review label
- reviewed_safe
- Generator SHA-256
- 8106b23c8b3e0d736293363f12c8adf7992aa0ae4354b345d48a6a2f013572d2
- Rule hash
- ae575d29554f
- Sources
- bank:e1d39660275b
- Lesson seeds
- 20261108, 20261109, 20261110, 20261111, 20261112
- Reproduce lesson 1
arcpuzzles generate cbd933916656 --count 1 --seed 20261108 --test 1