🦆 Rectangular Goose Walk
An animated explainer of the classic grid-spiral algorithm
Speed: Normal ×1
What is a Rectangular Goose Walk?

A Rectangular Goose Walk (also called a rectangular spiral traversal) visits every cell of a 2-D grid exactly once by peeling off one "layer" at a time — walking the top row →, then right column ↓, then bottom row ←, then left column ↑, then spiraling inward. Press Play to watch the goose go!