20
.*..*...*....*.....*
 97
****.***.***.*..**.**.*.*.***.*............*..*......*.***.**.*.***.*.***.*..*.**.*.***.**.*****.
 5
*.***
 4
****
 11
.*.*.*.*...
 72
.***.**.*.*...*****.*.*.*.*.**....**.*.**..*.*...**..***.**.**..*.**..**
 89
..**..**..*.********....*.*****.**.****...*......*******..*.**.*****..*..****....*...**..
 6
***.**
 54
...***.*...****.*..****....*..**..**..***.*..**...**..
 100
****************************************************************************************************
 53
*.*.****.*.*......**....**.***.*.*.**.*.*.***...*..*.
 87
*..*..***.**.*...****...*....***....***......*..*.*.*****.**..*.***...*.****..**.*..***
 90
**....****.***..***.*.*****...*.*.***..***.******.**...***..*...*****..*.**.**...*..**...*
 55
...*..*.*.**..*.*....*.****..****....*..***.*****..*..*
 21
*.*...*.*...*.*...*.*
 41
*******....*..*.**..***.*...****.***.*...
 31
.******.**.**....*.*********...
 64
*.***...**...*..*...*....*..***.*.*.*.***.*.**...**.*.*.*..*....
 10
*****....*
 99
**...*.*.*..*....**.***..*...***..***.**.*.....*.*....*...*.**.**.****..**..*.*..*.***....**...**.*
 69
.***...*.***.**...*....*.***.*..*....**.*...**....*.*..**....**..*.**
 99
.*.......................*.......................*.......................*.......................*.
 98
.**..**.*****..***...*.**..*..*....*******..**....*.****.**.*.....*.**..***.**..***.*******..****.
 57
**...*....**.**.*.******.**..**.*.....**.***..***...**..*
 64
***.*...*...*.***.....*.....**.*****.*.*...*..*.*..***..*...***.
 17
*...*...*...*...*
 100
*...............................................................................................****
 11
*...**..*.*
 1
.
 100
*.....................*.....................*.....................*.....................*...........
 56
**.*..*...***.*.**.**..**.*.*.*.**...*.**.**....*...**..
 99
***....*.....****.*.**.*.*.**.*.*.*..*...*..*...***..*.*...*.*...***.*.*...**.**.*******....**....*
 10
.*.*.*.*.*
 51
....****....*........*.*..**........*....****....*.
 17
.*..*..*.....*..*
 97
...*..*...*******.*.**..**..******.*.*..*****.*...***.*.**.**.**..**.******.****.*.***.**..*...**
 42
***.*..*.*.***...**..*..**....**..*..*...*
 5
*****
 42
..*...*.*..**..*.*.*..**...**.***.*.******
 71
**.**..*****.*.*.*.********.....*****.****.*..***...*.*.*.**.****.**.**
 5
.****
 99
.*..**..*..*..**...***.****.*...*....*****.....**..****.*..*....****..**..*****..*....**.*.**..**..
 42
.*.*...*..**.****...****..*.*.***....**...
 10
.*.*.*.*..
 1
*
 5
***.*
 16
*.**.**.**.*..*.
 100
*.......................*.......................*.......................*.......................*...
 7
***.***
 58
**.*.*.**..******.**.*..*.**.*.*******.**.*.**.*..*****.*.
 67
..**.*...*.....****.***.**.*....***..***.*..***.....*******.....*.*
 99
.*.......................*...............................................*.......................*.
 6
......
 11
.**.*..*.**
 15
..........*****
 75
..*.**..*.*****.......*....*.*.*..**.*.***.*.***....******.****.*.....****.
 45
.***..******....***..**..*.*.*.**..**..*.**..
 13
*..*..*..*..*
 5
**.**
 100
*****...............................................................................................
 99
..*.*..**.*.*.******.*.*.**.**.**.*..**.*.*****..*.*.****.*....**....*****.....***..**....***.*.*.*
 99
***************************************************************************************************
 5
****.

no yes no no no yes yes no yes yes yes yes yes yes no yes yes yes yes yes yes yes yes yes yes yes no no no yes yes yes yes no no yes yes yes yes yes no yes yes no no no yes yes no yes yes no no no yes yes yes yes no yes yes yes no
/* Programming competition file template
Made by Horatiu Lazu */

import java.io.*;
import java.util.*;
import java.lang.*;
import java.awt.*;
import java.awt.geom.*;
import java.math.*;


public class ProblemA{
	public static void main (String [] args){
		new ProblemA();
	}
	
	public boolean canJump(String a){
		/* find the first island */
		int startIsland = -1;
		int startIslandEnd = -1;
		for(int i = 0; i < a.length(); i++){
			if (a.charAt(i) == '*' && startIsland == -1){
				startIsland = i;	
			}
			if (a.charAt(i) == '.' && startIsland != -1){
				startIslandEnd = i;
				break;	
			}
		}
		boolean possible = false;
		for(int i = startIsland; i <= startIslandEnd - startIsland; i++){ //start point
			for(int x = 1; x <= a.length(); x++){
				try{
					boolean works = true;
					for(int p = 0; p < 4; p++){
						if (a.charAt(i + x + x * p) == '*'){
							boolean foundGap = false;
							for(int o = i + x + x * p; o >= i + x + x * (p-1); o--){
								if(a.charAt(o) == '.'){
									foundGap = true;	
									break;
								}
							}
							if (!foundGap){
								//System.out.println("Nope" + x + "try#" + p);
								p = 4;	
								works = false;
								break;
							}
							
						}
						else
							works = false;	
					}
					if (works){
						//System.out.println("from: " + i + "to: " + x);
						return true;	
					}
				}
				catch(IndexOutOfBoundsException e){
					x = a.length() + 1;
					break;
				}
			}
		}
		return false;
	}

	public ProblemA(){
		try{
			BufferedReader in;
			in = new BufferedReader (new InputStreamReader (System.in)); //Used for CCC
			
			int segments = Integer.parseInt(in.readLine());
			String input = in.readLine();
			
			//ArrayList<Distance> d = new ArrayList<Distance>();
			boolean checkPlatforms = false;
			if (canJump(input) == false){
				System.out.println("no");	
			}
			else{
				checkPlatforms = true;
				//System.out.println("yes");	
			}
			
			int [] jump = new int[segments + 1];
			int platforms = 0;
			//platforms++
			boolean start = true;
			boolean isPlatformA = false;
			boolean isPlatformB = false;
			int x1 = 0;
			int x2 = 0;
			int y1 = 0;
			int y2 = 0;
			boolean isHole = false;
			boolean isProcess = true;
			boolean donefirst = false;
			for(int i = 0; i < input.length(); i++){
				if (isProcess){
					
					if (input.charAt(i) == '*' && start){
						x1 = i;
						start = false;
						isPlatformA = true;
					}
					else if (isPlatformA){
						if (input.charAt(i) == '.'){
							if(donefirst == false){
								platforms++;
								donefirst = true;	
							}
							x2 = i-1;
							isPlatformA = false;
							isHole = true;
						}
					}
					else if (isHole){
						if (input.charAt(i) == '*'){
							y1 = i;
							isPlatformB = true;
							isHole = false;
							if (i == input.length() - 1){
								platforms++;
								y2 = i;
								isPlatformB = false;
								int min = y1 - x2;
								int max = y2 - x1;
								for(int x = min; x <= max; x++){
									jump[x]++;
								}
								//System.out.println("From " + x1 + " to " + x2 + "compared to : " + y1 + " to " + y2);
								//start = true;
								x1 = y1;
								x2 = y2;
								isHole = true;
							}
						}
					}
					else if(isPlatformB){
						
						if(input.charAt(i) == '.'){
							y2 = i - 1;
							isPlatformB = false;
							int min = y1 - x2;
							int max = y2 - x1;
							for(int x = min; x <= max; x++){
								jump[x]++;
							}
							//System.out.println("From " + x1 + " to " + x2 + "compared to : " + y1 + " to " + y2);
							//start = true;
							x1 = y1;
							x2 = y2;
							isHole = true;
							i--;
							platforms++;
						}
						else if (i == input.length() - 1){
							y2 = i;
							isPlatformB = false;
							int min = y1 - x2;
							int max = y2 - x1;
							for(int x = min; x <= max; x++){
								jump[x]++;
							}
							//System.out.println("From " + x1 + " to " + x2 + "compared to : " + y1 + " to " + y2);
							//start = true;
							x1 = y1;
							x2 = y2;
							isHole = true;
							platforms++;
						}
						
					}
					else{
						
					}
					
				}
				else{
					isPlatformB = false;
					isProcess = true;
					start = true;
				}
			}
			boolean found = false;
			for(int i = 0; i < jump.length; i++){
				//System.out.println(jump[i]);
				// && platforms == 5
				if (jump[i] == 4 && platforms == 5){
					
					found = true;
					//System.out.println("yes"); IGNORE THIS
					break;
				}
			}
			if (!found){
				//System.out.println("no");	
			}
			if (checkPlatforms){
				System.out.println("yes");	
			}
			else{
				System.out.println("no");	
			}
			//now to find the distances
			
			
		}
		catch(IOException e){
			System.out.println("IO: General");
		}
	}
}
