How do you solve word search in grid?

Updated Apr 28, 2026

Short answer

DFS with backtracking on grid.

Deep explanation

Explore all directions while marking visited cells temporarily.

Real-world example

Path finding in grids.

Common mistakes

  • Not restoring cell value.

Follow-up questions

  • Why mark visited?
  • Restore?

More Backtracking interview questions

View all →