#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  char A[100 + 3];
  cin >> n;
  cin >> A;
  int s = 1;
  while (s < (n / 4) + 1) {
    for (int i = 0; i < n && i + 4 * s < n; i++) {
      if (A[i] == '*' && A[i + s] == '*' && A[i + 2 * s] == '*' &&
          A[i + 3 * s] == '*' && A[i + 4 * s] == '*') {
        cout << "yes" << endl;
        return 0;
      }
    }
    s++;
  }
  cout << "no" << endl;
  return 0;
}
