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<cstdio>
#include<vector>
#include<stack>
#include<utility>

using namespace std;


int getLargestRectangle(vector<int>& H) {
  stack<pair<int, int> > S;
  int maxv = 0;
  H.push_back(0);

  for (size_t i = 0; i < H.size(); ++i) {
    pair<int, int> rect = make_pair(H[i], i);
    if (S.empty()) {
      S.push(rect);
    } else {
      if (S.top().first < rect.first)
        S.push(rect);
      else if (S.top().first > rect.first) {
        int target = i;
        while (!S.empty() && S.top().first >= rect.first) {
          pair<int, int> pre = S.top(); S.pop();
          int area = pre.first * (i - pre.second);
          maxv = max(maxv, area);
          target = pre.second;
        }
        rect.second = target;
        S.push(rect);
      }
    }
  }
  return maxv;
}


int getLargestRectangle(int h, int w, const vector<vector<bool> >& g) {
  vector<vector<int> > dp(h, vector<int>(w, 0));

  for (int i = 0; i < h; ++i) {
    for (int j = 0; j < w; ++j) {
      if (g[i][j]) dp[i][j] = 0;
      else {
        dp[i][j] = (i > 0) ? dp[i-1][j]+1 : 1;
      }
    }
  }

  int maxv = 0;
  for (int i = 0; i < h; ++i) {
    maxv = max(maxv, getLargestRectangle(dp[i]));
  }

  return maxv;
}

void solve(int h, int w) {
  vector<vector<bool> > g(h, vector<bool>(w, false));

  for (int i = 0 ; i < h; ++i)
    for (int j = 0; j < w; ++j) {
      int p;
      scanf("%d", &p);
      g[i][j] = p == 1;
    }

  printf("%d\n", getLargestRectangle(h, w, g));
}

int main() {

  int h, w;
  scanf("%d %d", &h, &w);
  
  solve(h, w);
  return 0;
}

