Word Search
Medium · Backtracking · about 20 minutes
Asked at Amazon, Microsoft, Bloomberg, Meta, JPMorgan Chase.
Given a grid of letters board (each row is a string) and a word, return true if the word can be built from letters of sequentially adjacent cells (horizontally or vertically). A cell may be used at most once per word.