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;

int m[1400][1400];
int dp[1400][1400];

int main()
{
	int a,b;
	scanf("%d%d", &a, &b);
	
	
	for(int i = 0; i < a; ++i){
		for(int j = 0; j < b; ++j){
			scanf("%d", &m[i][j]);
		}
	}
	
	for(int i = 0; i < b; ++i){
		dp[0][i] = (m[0][i] == 0)? 1 : 0;
	}
	
	for(int i = 1; i < a; ++i){
		for(int j = 0; j < b; ++j){
			dp[i][j] = (m[i][j] == 0)? 1 + dp[i-1][j] : 0;
		}
	}
	
	int resp = 0;
	
	for(int i = 0; i < a; ++i){
		
		vector<int> izq(b,0);
		izq[0] = -1;
		
		stack<pair<int,int> > el;
		el.push(make_pair(dp[i][0], 0));
		
		for(int j = 1; j < b; ++j){
			while(el.top().first >= dp[i][j]){
				el.pop();
				if(el.empty())break;
			}
			izq[j] = (el.empty())? -1 : el.top().second;
			el.push(make_pair(dp[i][j], j));
		}
		
		stack<pair<int,int> > el2;
		vector<int> der(b,0);
		der[b-1] = b;
		el2.push(make_pair(dp[i][b-1], b-1));
		
		for(int j = b-2; j >= 0; --j){
			while(el2.top().first >= dp[i][j]){
				el2.pop();
				if(el2.empty())break;
			}
			der[j] = (el2.empty())? b : el2.top().second;
			el2.push(make_pair(dp[i][j], j));
		}
		
		for(int j = 0; j < b; ++j){
			resp = max(resp, dp[i][j]*(der[j] - izq[j] - 1));
		}
		
	}
	
	printf("%d\n", resp);
	
}
