← 4a279b104523 · 4a6d26e0b6ae →
4a3ababcaceb
A regular lattice of 3x3 tiles separated by 9. Select the unique tile with the most red (2) cells, then REPLACE the distinct tile containing one green (3) marker with the source's red mask in cyan (8), zero elsewhere. Other tiles stay unchanged. Includes denser non-source tiles, weaker red candidates, non-red source clutter, target clutter and off-center markers.
source-target transfer, tile selection, motif copying
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 (flat grid) (apply append grid)) (define (take-n xs n) (if (or (= n 0) (empty? xs)) (list) (cons (first xs) (take-n (rest xs) (- n 1))))) (define (drop-n xs n) (if (or (= n 0) (empty? xs)) xs (drop-n (rest xs) (- n 1)))) (define (full-row? grid r color) (all? (lambda (c) (= (at grid r c) color)) (range 0 (cols grid)))) (define (full-col? grid c color) (all? (lambda (r) (= (at grid r c) color)) (range 0 (rows grid)))) (define (segments-from-dividers n dividers) (let loop ((ds (append dividers (list n))) (prev -1) (acc (list))) (if (empty? ds) (reverse acc) (let ((x (first ds))) (loop (rest ds) x (if (> (- x prev 1) 0) (cons (list (+ prev 1) x) acc) acc)))))) (define (tile-lattice grid) (let* ((divider-rows (filter (lambda (r) (full-row? grid r 9)) (range 0 (rows grid)))) (divider-cols (filter (lambda (c) (full-col? grid c 9)) (range 0 (cols grid)))) (row-bounds (segments-from-dividers (rows grid) divider-rows)) (col-bounds (segments-from-dividers (cols grid) divider-cols))) (map (lambda (rb) (map (lambda (cb) (subgrid grid (first rb) (first cb) (- (second rb) 1) (- (second cb) 1))) col-bounds)) row-bounds))) (define (flat-tiles grid) (let* ((tiles (tile-lattice grid)) (rs (length tiles)) (cs (length (first tiles)))) (list (apply append tiles) rs cs))) (define (assemble-tiles tile-matrix) (let* ((tr (length tile-matrix)) (tc (length (first tile-matrix))) (th (rows (first (first tile-matrix)))) (tw (cols (first (first tile-matrix)))) (h (+ (* tr th) (- tr 1))) (w (+ (* tc tw) (- tc 1)))) (for*/fold ((out (empty-grid h w 9))) ((rr (in-range tr)) (cc (in-range tc)) (r (in-range th)) (c (in-range tw))) (set-cell out (+ (* rr (+ th 1)) r) (+ (* cc (+ tw 1)) c) (at (list-ref (list-ref tile-matrix rr) cc) r c))))) (define (assemble-from-flat tiles rs cs) (let build-rows ((remaining tiles) (r 0) (rows-out (list))) (if (= r rs) (assemble-tiles (reverse rows-out)) (build-rows (drop-n remaining cs) (+ r 1) (cons (take-n remaining cs) rows-out))))) (let* ((ft (flat-tiles g)) (flat0 (first ft)) (rs (second ft)) (cs (third ft)) (twos (map (lambda (t) (count-color t 2)) flat0)) (src-idx (first (filter (lambda (i) (= (list-ref twos i) (apply max twos))) (range 0 (length flat0))))) (tgt-idx (first (filter (lambda (i) (> (count-color (list-ref flat0 i) 3) 0)) (range 0 (length flat0))))) (src (list-ref flat0 src-idx)) (newt (map (lambda (row) (map (lambda (v) (if (= v 2) 8 0)) row)) src)) (out (map (lambda (i) (if (= i tgt-idx) newt (list-ref flat0 i))) (range 0 (length flat0))))) (assemble-from-flat out rs cs))))
Provenance
- Generator
- generators/4a3ababcaceb/generator.py
- Notes and decisions
- generators/4a3ababcaceb/notes.md
- Review label
- reviewed_safe
- Generator SHA-256
- b29280e7128efaaf0ebc04e84a4b0f2235075eca5ed17855d582981002b42b7f
- Rule hash
- 3617779ffc60
- Sources
- bank:7f6d2146c992
- Lesson seeds
- 20261108, 20261109, 20261110, 20261111, 20261112
- Reproduce lesson 1
arcpuzzles generate 4a3ababcaceb --count 1 --seed 20261108 --test 1