At the Sirius Educational Center, students use various staircases for gathering and informal communication. The number of participants in the informatics olympiad significantly exceeds the number of participants in any other educational program, and there are no suitable staircases for them among the existing ones. Therefore, the facility management team decided to build a new staircase using a special template.
The template is a table with $h$ rows and $w$ columns, numbered from top to bottom and from left to right, respectively. Each cell of the table contains a number — either zero or one. A staircase can only be made from those cells of the table that contain a one.
The resulting staircase is formed by a set of cells containing ones that are located in several consecutive rows of the table. The set of selected cells in each row of the staircase must be a continuous segment. Furthermore, in each subsequent row included in the staircase, there must be no fewer cells selected than in the previous row, which is located directly above it, and the leftmost selected cells in each row must be located in the same column.
Below is an example of a staircase.
Find the maximum number of cells that form a staircase in the given table.
Input
The first line of the input contains two integers $h$ and $w$ ($1 \le h, w \le 2 \cdot 10^5$, $h \cdot w \le 4 \cdot 10^6$) — the number of rows and columns of the table, respectively.
Each of the following $h$ rows contains $w$ characters, each of which is 0 or 1 — the numbers written in the cells of the table.
Output
Output a single integer — the maximum number of cells that form a staircase.
Subtasks
| Subtask | Points | Constraints | Required Subtasks |
|---|---|---|---|
| 1 | 25 | $h, w \le 50$ | - |
| 2 | 25 | $h, w \le 400$ | 1 |
| 3 | 25 | $h \cdot w \le 200\,000$ | 1, 2 |
| 4 | 25 | - | 1, 2, 3 |
Examples
Input 1
6 4 0011 1101 0111 1110 0111 0100
Output 1
8
Note
The figure below shows the drawing for the first example. The staircase consisting of the maximum possible number of table cells is marked in gray.