N,A,B,C,D=list(map(int,input().split()))
l=list(input())
if "##" in "".join(l[A-1:max(C,D)-1]):
   print("No")
   exit()
if C>D:
   pass
else:
   print("Yes")
   exit()
if "..." in "".join(l[B-2:D+1]):
   print("Yes")
else:
   print("No") N,A,B,C,D=list(map(int,input().split())) N list(map(int,input().split())) list map(int,input().split()) map int input().split() ().split () input split A B C D l=list(input()) l list(input()) list input() input if "##" in "".join(l[A-1:max(C,D)-1]):
   print("No")
   exit() "##" in "".join(l[A-1:max(C,D)-1]) "##" "".join(l[A-1:max(C,D)-1]) "".join "" join l[A-1:max(C,D)-1] l A-1:max(C,D)-1 A-1 A 1 max(C,D)-1 max(C,D) max C D 1 print("No") print "No" exit() exit if C>D:
   pass
else:
   print("Yes")
   exit() C>D C D print("Yes") print "Yes" exit() exit if "..." in "".join(l[B-2:D+1]):
   print("Yes")
else:
   print("No") "..." in "".join(l[B-2:D+1]) "..." "".join(l[B-2:D+1]) "".join "" join l[B-2:D+1] l B-2:D+1 B-2 B 2 D+1 D 1 print("Yes") print "Yes" print("No") print "No" D=list(map(int,input().split())) list(map(int,input().split())) D l=list(input()) list(input()) l C,D=list(map(int,input().split())) list(map(int,input().split())) C B,C,D=list(map(int,input().split())) list(map(int,input().split())) B A,B,C,D=list(map(int,input().split())) list(map(int,input().split())) A N,A,B,C,D=list(map(int,input().split())) list(map(int,input().split())) N
N,A,B,C,D=list(map(int,input().split()))
l=list(input())
if "##" in "".join(l[A-1:max(C,D)-1]):
   print("No")
   exit()
if C>D:
   pass
else:
   print("Yes")
   exit()
if "..." in "".join(l[B-2:D+1]):
   print("Yes")
else:
   print("No")