⍝ Conway's Game of Life — toroidal one-liner ⍝ ⍝ Roger Hui formulation (without leading ⊃, since our inner-product ⍝ already produces a clean 2D board from a heterogeneous strand): ⍝ life ← {1 ⍵ ∨.∧ 3 4 = +/ +/ ¯1 0 1 ∘.⊖ ¯1 0 1 ⌽¨ ⊂⍵} ⍝ ⍝ Read right-to-left: ⍝ ⊂⍵ : enclose the board (so it's a single scalar item) ⍝ ¯1 0 1 ⌽¨ ⊂⍵ : produce 3 horizontally-shifted copies ⍝ ¯1 0 1 ∘.⊖ … : outer-product with vertical shifts → 3×3 = 9 shifts ⍝ +/ +/ … : sum the 9 boards element-wise → neighbor-count + self ⍝ 3 4 = … : leading-axis-extended boolean — count is 3 (born) or 4 (survive) ⍝ 1 ⍵ ∨.∧ … : "alive next" iff (count=3) or (alive AND count=4) ⍝ ⍝ Rules in plain language: ⍝ - dead cell + 3 live neighbors → born ⍝ - live cell + 2 or 3 live neighbors → survives ⍝ - all else → dies ⍝ ⍝ Toroidal: edges wrap (rotate is cyclic). life ← {1 ⍵ ∨.∧ 3 4 = +/ +/ ¯1 0 1 ∘.⊖ ¯1 0 1 ⌽¨ ⊂⍵}