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;
long long int dy[] = {0, 0, 1, -1};
long long int dx[] = {1, -1, 0, 0};
long long int const MOD = 1000000007;
namespace std {
bool operator<(const complex<double>& a, const complex<double>& b) {
  return a.real() != b.real() ? a.real() < b.real() : a.imag() < b.imag();
}
}  // namespace std
long long int board[1500][1500];
long long int dp[1500][1500];
struct Rectangle {
  long long int height, pos;
  Rectangle(long long int a, long long int b) : height(a), pos(b) {}
};
signed main() {
  long long int H, W;
  cin >> H >> W;
  memset(dp, 0, sizeof(dp));
  for (long long int(i) = (0); (i) < (H); (i)++)
    for (long long int(j) = (0); (j) < (W); (j)++) cin >> board[i][j];
  for (long long int(i) = (0); (i) < (H); (i)++)
    for (long long int(j) = (0); (j) < (W); (j)++) {
      if (board[i][j] == 1)
        dp[i][j] = 0;
      else {
        if (i == 0)
          dp[i][j] = 1;
        else
          dp[i][j] = dp[i - 1][j] + 1;
      }
    }
  long long int ans = 0;
  for (long long int(i) = (0); (i) < (H); (i)++) {
    stack<Rectangle> S;
    for (long long int(j) = (0); (j) <= (W); (j)++) {
      if (S.empty())
        S.push(Rectangle(dp[i][j], j));
      else {
        Rectangle TopRect = S.top();
        if (TopRect.height < dp[i][j])
          S.push(Rectangle(dp[i][j], j));
        else if (TopRect.height > dp[i][j]) {
          while (!S.empty() && TopRect.height > dp[i][j]) {
            long long int temp = (j - TopRect.pos) * TopRect.height;
            ans = max(ans, temp);
            S.pop();
            if (!S.empty()) TopRect = S.top();
          }
          if (S.empty())
            S.push(Rectangle(dp[i][j], 0));
          else {
            TopRect = S.top();
            if (TopRect.height != dp[i][j])
              S.push(Rectangle(dp[i][j], TopRect.pos + 1));
          }
        }
      }
    }
  }
  cout << ans << endl;
  return 0;
}
