N,A,B,C,D = map(int,input().split())
S = input()
if C == D:
    print("No")
    exit()
dot = 0
rock = 0
bol = 0
for i in range(1,N+1):
    if S[i-1] == ".":
        dot += 1
        rock = 0
        if dot >= 3 and B < i <= D + 1:
            bol = 1
    else:
        rock += 1
        dot = 0
        if rock >= 2 and A < i < max(C,D):
            print("No")
            exit()
if C < D:
    print("Yes")
    exit()
print("Yes" if bol == 1 else "No") N,A,B,C,D = map(int,input().split()) N map(int,input().split()) map int input().split() ().split () input split A B C D S = input() S input() input if C == D:
    print("No")
    exit() C == D C D print("No") print "No" exit() exit dot = 0 dot 0 rock = 0 rock 0 bol = 0 bol 0 for i in range(1,N+1):
    if S[i-1] == ".":
        dot += 1
        rock = 0
        if dot >= 3 and B < i <= D + 1:
            bol = 1
    else:
        rock += 1
        dot = 0
        if rock >= 2 and A < i < max(C,D):
            print("No")
            exit() i range(1,N+1) range 1 N+1 N 1 if S[i-1] == ".":
        dot += 1
        rock = 0
        if dot >= 3 and B < i <= D + 1:
            bol = 1
    else:
        rock += 1
        dot = 0
        if rock >= 2 and A < i < max(C,D):
            print("No")
            exit() S[i-1] == "." S[i-1] S i-1 i 1 "." dot += 1 dot 1 rock = 0 rock 0 if dot >= 3 and B < i <= D + 1:
            bol = 1
     dot >= 3 and B < i <= D + 1 dot >= 3 dot 3 B < i <= D + 1 B < i B i D + 1 D 1 bol = 1 bol 1 rock += 1 rock 1 dot = 0 dot 0 if rock >= 2 and A < i < max(C,D):
            print("No")
            exit() rock >= 2 and A < i < max(C,D) rock >= 2 rock 2 A < i < max(C,D) A < i A i max(C,D) max C D print("No") print "No" exit() exit if C < D:
    print("Yes")
    exit() C < D C D print("Yes") print "Yes" exit() exit print("Yes" if bol == 1 else "No") print "Yes" if bol == 1 else "No" bol == 1 bol 1 "Yes" "No" C,D = map(int,input().split()) map(int,input().split()) C dot = 0 0 dot B,C,D = map(int,input().split()) map(int,input().split()) B rock += 1 1 rock dot = 0 0 dot bol = 1 1 bol dot += 1 1 dot N,A,B,C,D = map(int,input().split()) map(int,input().split()) N S = input() input() S rock = 0 0 rock A,B,C,D = map(int,input().split()) map(int,input().split()) A rock = 0 0 rock D = map(int,input().split()) map(int,input().split()) D bol = 0 0 bol
N,A,B,C,D = map(int,input().split())
S = input()
if C == D:
    print("No")
    exit()
dot = 0
rock = 0
bol = 0
for i in range(1,N+1):
    if S[i-1] == ".":
        dot += 1
        rock = 0
        if dot >= 3 and B < i <= D + 1:
            bol = 1
    else:
        rock += 1
        dot = 0
        if rock >= 2 and A < i < max(C,D):
            print("No")
            exit()
if C < D:
    print("Yes")
    exit()
print("Yes" if bol == 1 else "No")