← SAP questions

Find any path in a maze from source to destination

Filed under SAP

Given an m x n binary grid where 0 represents an open path and 1 represents a wall, find any valid path from a source cell (sr, sc) to a destination cell (dr, dc). Movement is allowed in 4 cardinal…

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related SAP questions

Collected from public candidate posts and coding forums. Updated Nov 2026.