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;
typedef long long ll;
const int INF=2147483647;
const double pi=3.1415926535897932384626;
inline ll read(){
	ll x=0,f=1;
	char ch=getchar();
	while(ch<'0'||ch>'9'){
		if(ch=='-') f=-1;
		ch=getchar();
	}
	while(ch>='0'&&ch<='9'){
		x=(x<<1)+(x<<3)+(ch^48);
		ch=getchar();
	}
	return x*f;
}
const int maxn=1405;
int h,w,a[maxn][maxn],b[maxn][maxn],ans;
struct rectangle{
	int height,pos;
};
int solve(int w,int c[]){
	stack<rectangle> s;
	int maxx=0;
	c[w+1]=0;
	for(int i=1;i<=w+1;i++){
		rectangle rect;
		rect.height=c[i];
		rect.pos=i;
		if(s.empty()) s.push(rect);
		else{
			if(s.top().height<rect.height) s.push(rect);
			else if(s.top().height>rect.height){
				int target=i;
				while(!s.empty()&&s.top().height>=rect.height){
					rectangle pre=s.top();
					s.pop();
					int area=pre.height*(i-pre.pos);
					maxx=max(maxx,area);
					target=pre.pos;
				}
				rect.pos=target;
				s.push(rect);
			}
		}
	}
	return maxx;
}
int main(){
	h=read(),w=read();
	for(int i=1;i<=h;i++)
		for(int j=1;j<=w;j++)
			a[i][j]=read();		
	for(int i=1;i<=h;i++)
		for(int j=1;j<=w;j++)
			if(a[i][j]) b[i][j]=0;
			else b[i][j]=b[i-1][j]+1;
	for(int i=1;i<=h;i++) ans=max(ans,solve(w,b[i]));
	printf("%d\n",ans);
	return 0;
}
