Problem: We have a board with an H \times W grid. Each square in the grid is painted in black or white. The square at the i-th row from the top and j-th column from the left is black if the j-th character in S_i is `#`, and white if that character is `.`.

Snuke can perform the following operation on the grid any number of times:

* Select a row or column in the grid, and invert the color of all the squares in that row or column (that is, black squares become white and vice versa).



Then, Snuke draws a rectangle along grid lines. Here, all the squares contained in the rectangle must be painted in black.

Find the maximum possible area of Snuke's rectangle when the operation is performed optimally.

Constraints

* 2 \leq H \leq 2000
* 2 \leq W \leq 2000
* |S_i| = W
* S_i consists of `#` and `.`.

Input

Input is given from Standard Input in the following format:


H W
S_1
S_2
:
S_H


Output

Print the maximum possible area of Snuke's rectangle.

Examples

Input

3 3
..#
##.
.#.


Output

6


Input

3 3
..#
.
.#.


Output

6


Input

4 4
....
....
....
....


Output

16


Input

10 8
...#.#
...#.#
..###.#.
.##.#.#
.#..#.#.
..##.#.#
.#.#..
...#.#..
.#.##
..###


Output

27

Solution (in PYTHON3):

Solution:
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

"""
・2x2内の偶奇が不変量。これが偶数なら、そこは単色でとれる
・単色でとれる領域を調べる -> 色変更なしに大きい長方形をとる問題になる
・ベースラインを固定すると、ヒストグラムの長方形の問題（アリ本）
"""

H,W = map(int,readline().split())
grid = read().replace(b'\r',b'').replace(b'\n',b'')

H,W

# 左上に集める
cnt = [0]*(H*W)
for x in range(H*W):
    if grid[x]==ord('#'):
        # その場
        cnt[x]^=1
        # 左
        if x%W:
            cnt[x-1]^=1
        # 上
        if x>=W:
            cnt[x-W]^=1
        if x%W and x>=W:
            cnt[x-W-1]^=1

max_area = 0
height = [1]*(W-1)
for i in range(H-1):
    for j in range(W-1):
        if cnt[W*i+j]:
            height[j]=1
        else:
            height[j]+=1
    # 最大長方形の変種。
    stack=[]
    for j,h in enumerate(height+[0]):
        while stack:
            prev_h = height[stack[-1]]
            if prev_h < h:
                break
            stack.pop()
            left_end = -1 if not stack else stack[-1]
            area = (j-left_end)*prev_h
            if max_area < area:
                max_area = area
        stack.append(j)

# 幅1の長方形は2x2を素材としない
if max_area < max(W,H):
    max_area = max(W,H)
print(max_area)