FastPrepFind a Word in a Letter Grid
Problems/Find a Word in a Letter Grid

Find a Word in a Letter Grid

Meta logoMeta● MediumFULLTIMEONSITE INTERVIEW

Updated Oct 2026

QuestionFunctionExamplesConstraints

Problem statement

Source note: A Meta E5 machine-learning engineer candidate reports an unspecified variation of the linked Word Search problem in a post-phone interview loop. The precise variation was not described. This practice uses the linked public four-direction, no-cell-reuse rules and 6-by-6 board and 15-letter word bounds. Source match is about 65%.

Given a rectangular character grid board and a string word, return true if word can be formed by a path through the grid. Otherwise, return false.

A path may move horizontally or vertically between adjacent cells. The same grid cell cannot be used more than once in one path.

Function

wordExists(board: char[][], word: String) → boolean

Examples

Example 1

board = [["A","B","C","E"],["S","F","C","S"],["A","D","E","E"]]word = "ABCCED"return = true
board
01230ABCE1SFCS2ADEE

The path uses the top-row cells A, B, and C, then continues down to C, left to E, and left to D.

Example 2

board = [["A","B","C","E"],["S","F","C","S"],["A","D","E","E"]]word = "ABCB"return = false
board
01230ABCE1SFCS2ADEE

The only adjacent B that could finish the word is the cell already used after the starting A, and a cell cannot be reused.

Example 3

board = [["A"]]word = "A"return = true
board
00A

The single grid cell forms the complete word.

Example 4

board = [["A","B","C","E"],["S","F","C","S"],["A","D","E","E"]]word = "SEE"return = true
board
01230ABCE1SFCS2ADEE

The path uses the rightmost S followed by the two neighboring E cells.

Constraints

  • 1 <= board.length <= 6
  • 1 <= board[i].length <= 6
  • Every row of board has the same length.
  • 1 <= word.length <= 15
  • board and word contain only uppercase and lowercase English letters.

More Meta Onsite Interview questions

  • Multi-Head Attention Forward PassPHONE SCREEN · ONSITE INTERVIEW · Seen Nov 2026
  • Run-Length Encoded Vector Dot ProductPHONE SCREEN · ONSITE INTERVIEW · Seen Nov 2026
  • Mutual-Friend RecommendationsPHONE SCREEN · ONSITE INTERVIEW · Seen Nov 2026
  • Deterministic K-Means AssignmentsPHONE SCREEN · ONSITE INTERVIEW · Seen Sep 2026
  • Linear Layer Forward and Backward PassesONSITE INTERVIEW · Seen Sep 2026
  • Reservoir Sampling with Recorded DrawsONSITE INTERVIEW · Seen Sep 2026
  • Stochastic Gradient Descent with MomentumONSITE INTERVIEW · Seen Sep 2026
  • Top K Largest Values with a HeapONSITE INTERVIEW · Seen Sep 2026
  • Partition a Card Deck into FifteensONSITE INTERVIEW · Seen Sep 2026
  • Insert into a Sorted Circular ListONSITE INTERVIEW · Seen Aug 2026

Similar questions at other companies

  • Word SearchBloomberg LP · OA · PHONE SCREEN · ONSITE INTERVIEWBloomberg LP interview questions
  • Word SearchAmazon · ONSITE INTERVIEW
  • Word SearchMicrosoft · ONSITE INTERVIEWMicrosoft interview questions
  • Enumerate Character Paths to a MarkerTesla · ONSITE INTERVIEWTesla interview questions
  • Trace a Word Through a Letter GridExpedia · ONSITE INTERVIEWExpedia interview questions
  • Enumerate Top-to-Bottom Grid PathsGoogle · ONSITE INTERVIEWGoogle interview questions
  • Check Each Word in a Character GridZillow · ONSITE INTERVIEWZillow interview questions
  • Word SearchCognitiv · PHONE SCREEN
  • Find a Word in a Letter GridAdobe · PHONE SCREENAdobe interview questions
  • Word SearchWhatNot · PHONE SCREENWhatNot interview questions

Meta interview experiences

  • Meta PhD SWE Intern AI Coding Phone Screen: 1 Experience
  • Meta Business Support Engineer Phone Screen: 1 Experience
  • Meta Software Engineer Onsite Questions: 3 Experiences
  • Meta AI Native Engineer OA and Onsite: 1 Experience
  • Meta AI-Native Coding Interview: 3 Experiences
  • Meta Production Engineer Intern Questions: 6 Experiences
All Meta interview questionsSee Meta hiring insights
Saved
class Solution {
    public boolean wordExists(char[][] board, String word) {
      // Write your code here.
    }

}
Checking account…