#include <bits/stdc++.h>
using namespace std;
using ll = int64_t;
using pi = pair<ll, ll>;
using vi = vector<ll>;
using ld = long double;
template <class T, class U>
ostream &operator<<(ostream &os, const pair<T, U> &p) {
  os << "(" << p.first << "," << p.second << ")";
  return os;
}
template <class T>
ostream &operator<<(ostream &os, const vector<T> &v) {
  os << "{";
  for (ll i = ll(0); i < ll((ll)v.size()); i++) {
    if (i) os << ",";
    os << v[i];
  }
  os << "}";
  return os;
}
ll read() {
  ll i;
  scanf("%" SCNd64, &i);
  return i;
}
void printSpace() { printf(" "); }
void printEoln() { printf("\n"); }
void print(ll x, ll suc = 1) {
  printf("%" PRId64, x);
  if (suc == 1) printEoln();
  if (suc == 2) printSpace();
}
string readString() {
  static char buf[3341000];
  scanf("%s", buf);
  return string(buf);
}
char *readCharArray() {
  static char buf[3341000];
  static ll bufUsed = 0;
  char *ret = buf + bufUsed;
  scanf("%s", ret);
  bufUsed += strlen(ret) + 1;
  return ret;
}
template <class T, class U>
void chmax(T &a, U b) {
  if (a < b) a = b;
}
template <class T, class U>
void chmin(T &a, U b) {
  if (b < a) a = b;
}
template <class T>
T Sq(const T &t) {
  return t * t;
}
signed main() {
  ll N = read(), ans = 0;
  string S = readString();
  for (ll i = ll(1); i < ll(N); i++) {
    if (S[i] == '.') ans++;
  }
  print(ans);
}
