Maximum Number of Points from Grid Queries
CodingPhoneSoftware EngineerReported May, 2026Medium Frequency
Company question banks are included with the Insider plan.
You are given an integer matrix grid and an array queries. Starting from the top-left cell, you may move in four directions.
For each query value q, count how many cells can be reached using...