Hacker Challenge: Spiral Grid Pattern
Learn to initialize a 2-D array in a spiral pattern.
In this lesson, we’ll be practicing more with multi-dimensional arrays. We’ll start by initializing a square matrix in a spiral pattern. We’ll then map the same 2-D spiral-patterned grid to a 1-D grid.
Get hands-on with 1200+ tech skills courses.