#include <bits/stdc++.h>
int good(char *s, int n, int l, int i) {
  return i + l * 4 < n && s[i] == '*' && s[i + l] == '*' &&
         s[i + (l * 2)] == '*' && s[i + (l * 3)] == '*' &&
         s[i + (l * 4)] == '*';
}
int main() {
  static char s[100 + 1];
  int n, i, l;
  scanf("%d%s", &n, s);
  for (l = 1; l < n; l++)
    for (i = 0; i < n; i++)
      if (good(s, n, l, i)) {
        printf("yes\n");
        return 0;
      }
  printf("no\n");
  return 0;
}
