Given a matrix of 0s and 1s, start at (0,0) moving right. When encountering a 0, continue in the current direction. When encountering a 1, flip it to 0 and turn 90 degrees clockwise (right relative to…
You've read your 3 free write-ups
Sign up free to keep reading. Your account opens the first 10 questions of every company.