← 0fcb77c31d06 · 1034300a135f →

0ff4b77946cc

0-bg grid (h ∈ 8-16, w ∈ 11-18, by difficulty) with: N_SHAPES ∈ 3-4 OBJECTS drawn from _SHAPES bank (6 variants of sizes 1, 3, 4, 5, 8, 9 — single cell, L, T-pentomino, ring 3×3, solid 3×3), each with a DISTINCT SIZE drawn WITHOUT REPLACEMENT, each painted in a DISTINCT color from {1..9}, placed via place_no_overlap with 1-cell padding. Total packed width fits within w. Rule (SORT OBJECTS BY (SIZE DESC, BBOX-H ASC, BBOX-W ASC, COLOR ASC); PACK THEM HORIZONTALLY FROM THE LEFT WITH 1-COL BG GAPS, PRESERVING EACH OBJECT'S ORIGINAL SHAPE AND COLOR): EXTRACT every non-bg component. SORT by tuple (-cell_count, bbox_h, bbox_w, color). CROP each to its bbox. PACK left-to-right with 1-COLUMN BG GAPS between, TOP-ALIGNED. Output height = max bbox height across all objects; width = sum_widths + (n-1). Net: largest objects go first, left-aligned packing yields a sorted gallery.

parametric familyarea rankingcomponent extractionstrip packing

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).

Reference rule (Racket)

(rule!
  (let ((objs (sort (objects g 0)
                    (lambda (a b)
                      (cond [(not (= (obj-size a) (obj-size b))) (> (obj-size a) (obj-size b))]
                            [(not (= (obj-h a) (obj-h b))) (< (obj-h a) (obj-h b))]
                            [(not (= (obj-w a) (obj-w b))) (< (obj-w a) (obj-w b))]
                            [else (< (obj-color a) (obj-color b))])))))
    (grid-from-fn (rows g) (cols g)
      (lambda (r c)
        (let loop ([remaining objs] [offset 0])
          (cond [(empty? remaining) 0]
                [(and (>= c offset) (< c (+ offset (obj-w (first remaining)))))
                 (let* ((obj (first remaining)) (rr (+ (obj-r1 obj) r)) (cc (+ (obj-c1 obj) (- c offset))))
                   (if (and (< r (obj-h obj)) (member? (list rr cc) (obj-cells obj))) (at g rr cc) 0))]
                [else (loop (rest remaining) (+ offset (obj-w (first remaining)) 1))]))))))

Provenance

Generator
generators/0ff4b77946cc/generator.py
Notes and decisions
generators/0ff4b77946cc/notes.md
Review label
reviewed_safe
Generator SHA-256
b18135054a7caa9edcc65f3e3262c77aaef95f3d17a10a2266677854eb15fb0b
Rule hash
21ac0e8cb5dd
Sources
bank:26462ff56908
Lesson seeds
20261108, 20261109, 20261110, 20261111, 20261112
Reproduce lesson 1
arcpuzzles generate 0ff4b77946cc --count 1 --seed 20261108 --test 1