Largest Open Plot
field is a map of a farm given as a list of equal-length strings, where . is open ground and # is a rock. A plot is a rectangle of cells, aligned with the grid, that holds open ground only.
Return the number of cells in the largest plot, or 0 if there is no open ground.
Example 1
field ["..#..",".....","#...."]
returns 8
Rows 1 and 2 with columns 1 to 4 form an open plot of 2 by 4 cells.
Example 2
field ["#"]
returns 0
The only cell is a rock.
Constraints
1 <= len(field) <= 101 <= len(field[r]) <= 10, and all rows have the same lengthfield[r]holds.and#only
Write it in your browser, against the clock. The model solution, stepped through line by line, comes after.