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;
static const int MAX = 1400;
struct Rectangle {
 public:
  int height, pos;
  Rectangle(int height, int pos) : height(height), pos(pos) {}
};
int G[MAX][MAX];
int H, W;
int getLargestRectangle() {
  stack<Rectangle> S;
  int dp[H][W];
  int maxArea = 0;
  for (int i = 0; i < H; i++) {
    for (int j = 0; j < W; j++) {
      dp[i][j] = (G[i][j] + 1) % 2;
      if (i != 0 && dp[i][j] != 0) dp[i][j] += dp[i - 1][j];
    }
  }
  for (int i = 0; i < H; i++) {
    for (int j = 0; j < W; j++) {
      Rectangle rect = Rectangle(dp[i][j], j);
      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 = j;
          while (!S.empty() && S.top().height > rect.height) {
            maxArea = max(maxArea, (target - S.top().pos) * S.top().height);
            target = S.top().pos;
            S.pop();
          }
        }
      }
    }
    int target = W;
    while (!S.empty()) {
      maxArea = max(maxArea, (target - S.top().pos) * S.top().height);
      target = S.top().pos;
      S.pop();
    }
  }
  return maxArea;
}
int main() {
  int c;
  cin >> H >> W;
  for (int i = 0; i < H; i++) {
    for (int j = 0; j < W; j++) cin >> G[i][j];
  }
  cout << getLargestRectangle() << endl;
}
