Yext Interview Question

Best way to navigate 2d array in a specific snakey pattern