← 49bfa2fd18b7 · 49f2e1c9f51a →

49c16a3506ab

Background 6. Each non-6 color has one solid 3x3 corner block. Scattered same-color cells slide toward their own block: row-band cells horizontally, column-band cells vertically, and all others diagonally, stopping adjacent to the block.

parametric family

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! (lambda (g)
  ;; Each color has a solid 3x3 block in one corner (bg=6). Scattered same-color
  ;; cells slide onto the block: row-band cells slide horizontally, col-band cells
  ;; vertically, diagonal cells diagonally toward the corner, stopping adjacent to
  ;; the block edge (compositional slide, not a memorized patch table).
  (let* ((H (rows g)) (W (cols g)) (bg 6)
         (palette (filter (lambda (c) (not (= c bg))) (grid-colors g))))
    (foldl
      (lambda (col acc)
        (let* ((corners (list (list 0 0) (list 0 (- W 3)) (list (- H 3) 0) (list (- H 3) (- W 3))))
               (corner (findf
                         (lambda (rc)
                           (andmap (lambda (dr)
                                     (andmap (lambda (dc) (= (cell-at g (+ (first rc) dr) (+ (second rc) dc)) col)) (list 0 1 2)))
                                   (list 0 1 2)))
                         corners))
               (r0 (first corner)) (c0 (second corner))
               (hdir (if (= c0 0) -1 1))
               (vdir (if (= r0 0) -1 1))
               (inblock? (lambda (r c) (and (>= r r0) (<= r (+ r0 2)) (>= c c0) (<= c (+ c0 2)))))
               (scattered (filter (lambda (rc) (not (inblock? (first rc) (second rc)))) (find-color g col))))
          (foldl
            (lambda (rc a)
              (let* ((r (first rc)) (c (second rc))
                     (rowband (and (>= r r0) (<= r (+ r0 2))))
                     (colband (and (>= c c0) (<= c (+ c0 2))))
                     (dr (if colband vdir (if rowband 0 vdir)))
                     (dc (if rowband hdir (if colband 0 hdir))))
                (letrec ((slide (lambda (rr cc)
                                  (let ((nr (+ rr dr)) (nc (+ cc dc)))
                                    (if (or (< nr 0) (>= nr H) (< nc 0) (>= nc W) (inblock? nr nc))
                                        (list rr cc)
                                        (slide nr nc))))))
                  (let* ((dest (slide r c))
                         (a2 (set-cell a r c bg)))
                    (set-cell a2 (first dest) (second dest) col)))))
            acc scattered)))
      g palette))))

Provenance

Generator
generators/49c16a3506ab/generator.py
Notes and decisions
generators/49c16a3506ab/notes.md
Review label
reviewed_safe
Generator SHA-256
4f0a0a76b26e3fdff021a7009bf890ddc707265cc0d7b86311b57f9d1696e894
Rule hash
b81d150b289c
Sources
augmented, training
Lesson seeds
20261108, 20261109, 20261110, 20261111, 20261112
Reproduce lesson 1
arcpuzzles generate 49c16a3506ab --count 1 --seed 20261108 --test 1