{"raw_statement":[{"iden":"problem statement","content":"We have a grid with $H$ horizontal rows and $W$ vertical columns of squares, where each square is tidy or untidy.\nYou will now place a mattress on this grid.\nThe mattress can be placed on two horizontally or vertically adjacent tidy squares in the grid.\nGiven are integers $H$, $W$, and $H$ strings $S_i$ of length $W$ each. If the $j$\\-th character of $S_i$ is `.`, the square at the $i$\\-th row from the top and the $j$\\-th column from the left is tidy; if the $j$\\-th character of $S_i$ is `#`, the square at the $i$\\-th row from the top and the $j$\\-th column from the left is untidy.\nFind the number of ways to choose the position for the mattress."},{"iden":"constraints","content":"*   $2 \\leq H \\leq 100$\n*   $2 \\leq W \\leq 100$\n*   $S_i$ is a string of length $W$ consisting of `.` and `#`."},{"iden":"input","content":"Input is given from Standard Input in the following format:\n\n$H$ $W$\n$S_1$\n$:$\n$S_H$"},{"iden":"sample input 1","content":"2 3\n..#\n#.."},{"iden":"sample output 1","content":"3\n\nWe have the following three choices:\n\n*   the $1$\\-st and $2$\\-nd squares from the left in the $1$\\-st row from the top;\n*   the $2$\\-nd and $3$\\-rd squares from the left in the $2$\\-nd row from the top; and\n*   the $1$\\-st and $2$\\-nd squares from the top in the $2$\\-nd column the left."},{"iden":"sample input 2","content":"2 2\n.#\n#."},{"iden":"sample output 2","content":"0"}],"translated_statement":null,"sample_group":[],"show_order":["default"],"formal_statement":null,"simple_statement":null,"has_page_source":true}