In a square area of size , cells are numbered sequentially from to from the top row to the bottom, from left to right in each row.
Nyasyr stands in the cell with number in this area and wants to find the sum of the numbers of all neighboring cells. Help Nyasyr with this task.
Note that each cell can have no more than neighbors directly above, below, to the left, and to the right.
Below is an example with and .
Here Nyasyr stands on the cell with number , and neighboring cells are marked with circles. In this case, there is no neighbor on the right.
Two integers and .
Print the sum of the numbers of all neighboring cells of the given cell.