A: Taking a Seat-Taking a Seat-

story

Mr. A entered the classroom at the examination site to take an examination. However, Mr. A is a very nervous type. Therefore, depending on the situation, there may be seats that Mr. A does not want to sit in. Therefore, Mr. A decided to find out how many seats he could sit on based on certain conditions.

problem

Mr. A is a nervous type of person. First of all, Mr. A cannot sit in the first row from the front. Because when I sit near the proctor, I get nervous and can't solve the problem. Also, if there is a person on the right or left, Mr. A cannot sit down. This is because the sound of the pencil next to me makes it impossible to concentrate during the test. In addition, you can't sit near a noisy guy (near 8 diagonally up, down, left, and right). This is because my voice echoes in my head during the break and I can't rest. Also, it's natural, but I can't sit in the seat where the students are already sitting.

Is there a place where Mr. A can sit under these conditions? Assuming that M x N seats are lined up in the classroom, let's find the number.

Input format

The first row gives M (number of rows: number of vertical seats) and N (number of columns: number of horizontal seats). From the second line, M lines and a character string of length N are given line by line. The j character of the i-th character string represents the state of the seat in the i-th row and the j-th column. Each letter is either'-',' x'or'o', vacant seats'-', noisy students sitting during breaks'x', other students sitting' Let it be o'.

Constraint

* 0 <M ≤ 100
* 0 <N ≤ 100



Output format

Output the number of seats that Mr. A can sit in one line depending on the conditions. Don't forget the line break at the end.

Input example 1


5 5
--o--
--xo-
--x--
o --- x
--xoo


Output example 1


3

Input example 2


2 6
--oooo
x--o--


Output example 2


1

Input example 3


3 5
-----
-----
-----


Output example 3


Ten

Input example 4


4 6
o-oxoo
oo-ooo
oooxo-
o-ooox


Output example 4


0





Example

Input

5 5
--o--
--xo-
--x--
o---x
--xoo


Output

3
#include<bits/stdc++.h>
using namespace std;
using ll = long long;
using P = pair<int,int>;
#define enld '\n'
#define rep(i,n) for(int i=0; i<(n); i++)
#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")
#pragma GCC optimize("Ofast")
constexpr ll INF = 1e18;
constexpr int inf = 1e9;
constexpr ll mod = 1000000007;
constexpr ll mod2 = 998244353;
const double PI = 3.1415926535897932384626433832795028841971;
const int dx[8] = {1, 0, -1, 0,1,1,-1,-1};
const int dy[8] = {0, 1, 0, -1,1,-1,-1,1};
template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return 1; } return 0; }
template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return 1; } return 0; }
// ---------------------------------------------------------------------------


int main(){
    ios::sync_with_stdio(false);
    cin.tie(nullptr);
    int H,W;
    cin >> H >> W;
    vector<string> G(H);
    rep(i,H) cin >> G[i];
    vector<vector<bool>> ok(H,vector<bool> (W,true));
    rep(i,H){
        rep(j,W){
            if(G[i][j] == 'o'){
                ok[i][j] = false;
                int ny = i;
                int nx = j+1;
                if(nx<W){
                    ok[ny][nx] = false;
                }
                nx = j-1;
                if(nx>=0){
                    ok[ny][nx] = false;
                }
            }else if(G[i][j] == 'x'){  
                ok[i][j] = false;
                for(int k=0; k<8; k++){
                    int ny = i+dy[k];
                    int nx = j+dx[k];
                    if(ny<0 or ny>=H or nx<0 or nx>=W) continue;
                    ok[ny][nx] = false;
                }
            }
        }
    }
    // for(int i=0; i<H; i++){
    //     for(int j=0; j<W; j++){
    //         cout << (ok[i][j]) << " \n"[j+1==W];
    //     }
    // }
    int cnt = 0;
    for(int i=1; i<H; i++){
        rep(j,W){
            if(ok[i][j]) cnt++;
        }
    }
    cout << cnt << "\n";
    return 0;
}

