Given a matrix (H × W) which contains only 1 and 0, find the area of the largest rectangle which only contains 0s.

Constraints

* 1 ≤ H, W ≤ 1,400

Input


H W
c1,1 c1,2 ... c1,W
c2,1 c2,2 ... c2,W
:
cH,1 cH,2 ... cH,W


In the first line, two integers H and W separated by a space character are given. In the following H lines, ci,j, elements of the H × W matrix, are given.

Output

Print the area (the number of 0s) of the largest rectangle.

Example

Input

4 5
0 0 1 0 0
1 0 0 0 0
0 0 0 1 0
0 0 0 1 0


Output

6
#include<bits/stdc++.h>
using namespace std;
 
using lint=long long;

template<typename T> T LargestRectangle(vector<T>& h)
{
   // be careful not to overflow
   int N=h.size();
   vector<int> l(N),r(N);
   stack<int> S;
   for(int i=0;i<N;i++){
      while(!S.empty() and h[S.top()]>=h[i]) S.pop();
      l[i]=(S.empty()? 0:S.top()+1); S.push(i);
   }
   S=stack<int>();
   for(int i=N-1;i>=0;i--){
      while(!S.empty() and h[S.top()]>=h[i]) S.pop();
      r[i]=(S.empty()? N:S.top()); S.push(i);
   }
   T res=0;
   for(int i=0;i<N;i++) res=max(res,h[i]*(r[i]-l[i]));
   return res;
}

int main()
{
   int H,W; cin>>H>>W;
   vector<vector<int>> c(H,vector<int>(W));
   for(int i=0;i<H;i++) for(int j=0;j<W;j++) cin>>c[i][j];

   vector<vector<int>> cntU(H,vector<int>(W));
   for(int j=0;j<W;j++){
      int cnt=0;
      for(int i=0;i<H;i++){
         if(c[i][j]) cnt=0; else cnt++;
         cntU[i][j]=cnt;
      }
   }
   int ans=0;
   for(int i=0;i<H;i++) ans=max(ans,LargestRectangle(cntU[i]));
   cout<<ans<<endl;
   return 0;
}

