#include <bits/stdc++.h>
using namespace std;
inline void read(int &x) {
  char ch;
  int t = 0;
  x = 0;
  for (ch = getchar(); ch < '0' || ch > '9'; ch = getchar())
    if (ch == '-') t = 1;
  for (; ch >= '0' && ch <= '9'; x = x * 10 + ch - 48, ch = getchar())
    ;
  if (t) x = -x;
}
const int N = 105, mod = 1e9 + 7;
char str[N];
int main() {
  int n, i, j, k, l, r, p, T, m;
  int s, t, x, y, a, b;
  while (~scanf("%d", &n)) {
    scanf("%s", str);
    for (i = 0; i < n; i++) {
      for (j = 1; j < n; j++) {
        for (k = 0; k < 5; k++)
          if (i + k * j >= n || str[i + k * j] != '*') break;
        if (k == 5) goto out;
      }
    }
  out:
    if (k == 5)
      printf("yes\n");
    else
      printf("no\n");
  }
  return 0;
}
