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
#define _USE_MATH_DEFINES

#include <cstdio>
#include <cstdlib>
#include <iostream>
#include <cmath>
#include <algorithm>
#include <vector>
#include <queue>
#include <stack>
#include <map>

using namespace std;

typedef pair<long long int, long long int> P;
long long int INF = 1e18;

long long int h[1500] = {}, L[1500], R[1500];

int main(){
	
	int H, N;
	cin >> H >> N;
	
	long long int ans = 0;
	
	for(int loop = 0; loop < H; loop++){
		for(int j = 0; j < N; j++){
			int num;
			cin >> num;
			if(num){
				h[j] = 0;
			}else{
				h[j]++;
			}
		}
		
		stack<int> sta;
		
		for(int i = 0; i < N; i++){
			while(sta.size() > 0 && h[sta.top()] >= h[i]){
				sta.pop();
			}
			if(sta.empty()){
				L[i] = 0;
			}else{
				L[i] = sta.top() + 1;
			}
			sta.push(i);
		}
		
		while(!sta.empty()){
			sta.pop();
		}
		
		for(int i = N - 1; i >= 0; i--){
			while(sta.size() > 0 && h[sta.top()] >= h[i]){
				sta.pop();
			}
			if(sta.empty()){
				R[i] = N;
			}else{
				R[i] = sta.top();
			}
			sta.push(i);
		}
		
		while(!sta.empty()){
			sta.pop();
		}
		
		for(int i = 0; i < N; i++){
			ans = max(ans, h[i] * (R[i] - L[i]));
		}
	}
	cout << ans << endl;
	
	return 0;
}
