← 84def340ce03 · 85305305afdf →

84fd4bcdc53c

0-bg grid (easy ~8x10 -> hard up to ~19x20) with 1-4 distinct non-bg colors (scaled by difficulty), each with 2-4 ENDPOINT cells placed at DISTINCT rows AND distinct cols (so consecutive endpoints define a clear L-bend). Rule: for each color, sort its cells in scan order (row-major). Connect consecutive cells with an L-PATH: first horizontal segment from (r1, c1) to (r1, c2), then vertical segment from (r1, c2) to (r2, c2). Paint every cell along the L-path with that color. Net: endpoints become connected by staircase L-paths.

parametric familyManhattan pathmarker orderpolyline tracing

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 ((dummy 0))
    (define (step-range a b)
      (if (<= a b) (range a (+ b 1)) (reverse (range b (+ a 1)))))
    (define (trace points)
      (if (empty? points)
          (list)
          (let loop ([remaining (rest points)] [prev (first points)] [out (list (first points))])
            (if (empty? remaining)
                (reverse (foldl (lambda (p acc) (if (member p acc) acc (cons p acc))) (list) (reverse out)))
                (let* ((next (first remaining))
                       (r1 (first prev)) (c1 (second prev))
                       (r2 (first next)) (c2 (second next))
                       (hpart (map (lambda (c) (list r1 c)) (rest (step-range c1 c2))))
                       (vpart (map (lambda (r) (list r c2)) (rest (step-range r1 r2)))))
                  (loop (rest remaining) next (append out hpart vpart)))))))
    (for/fold ([out (empty-grid (rows g) (cols g) 0)]) ([color (in-list (grid-colors g 0))])
      (for/fold ([acc out]) ([p (in-list (trace (find-color g color)))])
        (if (= (at acc (first p) (second p)) 0)
            (set-cell acc (first p) (second p) color)
            acc)))))

Provenance

Generator
generators/84fd4bcdc53c/generator.py
Notes and decisions
generators/84fd4bcdc53c/notes.md
Review label
reviewed_safe
Generator SHA-256
753aada7137e8bc5e6b34bfacafd619b4c4da08a9a02f72d882e6c22d1a12703
Rule hash
fc4401cc4027
Sources
bank:f3a2e93ae563
Lesson seeds
20261108, 20261109, 20261110, 20261111, 20261112
Reproduce lesson 1
arcpuzzles generate 84fd4bcdc53c --count 1 --seed 20261108 --test 1