Write a c program to accept an nm matrix containing only 0


Write a C++ program to accept an n*m matrix containing only 0 and 1 values, and then find it's biggest zero submatrix i.e. the biggest submatrix in which all the values are 0.

INPUT

First line contains two numbers n, m (n,m<=300),
then n lines, each having m 0/1 digits.

OUTPUT

One number, which represent the number of zeros inside the biggest zero submatrix.

SAMPLE INPUT

6 5
0 0 0 0 0
0 1 1 1 0
0 1 0 1 0
0 1 1 1 0
0 0 0 0 0
0 0 0 0 0

SAMPLE OUTPUT

10

Solution Preview :

Prepared by a verified Expert
C/C++ Programming: Write a c program to accept an nm matrix containing only 0
Reference No:- TGS01247196

Now Priced at $20 (50% Discount)

Recommended (94%)

Rated (4.6/5)