2506. Minimize Maximum Value in a Grid

Hard
Array
Union Find
Graph
Topological Sort
Sorting
Matrix

Description

Hints

Hint 1
Can you think of which element in the grid you should replace first?
Hint 2
Replace the elements in the matrix from the smallest number to the largest. Replace each element with the smallest possible number so far.

Similar Questions

Statistics

Acceptance
70.2%
Submissions
10,423
Accepted
7,315