matrix is a grid of m rows and n columns. Each cell holds the string "0" or "1". Find the largest square made only of "1" cells, and return its area: the number of cells in it.
The bottom three rows of the second, third and fourth columns are all "1": a 3 × 3 square, area 9. No 4 × 4 square fits, because every one would cover a "0".
With no "1" at all there is no square.
A single row only holds squares of side 1.
Constraints
m == matrix.lengthn == matrix[i].length1 <= m, n <= 300matrix[i][j] is "0" or "1".If a cell is the bottom-right corner of a k × k square of "1"s, then the cells above it, to its left and diagonally up-left are each corners of a square at least (k − 1) × (k − 1).
9