n, a, b, c, d = map(int, input().split())

s = input()

if c < d:
    if "##" in s[a-1:c] or "##" in s[b-1:d]:
        print("No")
    else:
        print("Yes")
else:
    if "..." in s[b-2:d+1] and "##" not in s[a-1:c] and "##" not in s[b-1:d]:
        print("Yes")
    else:
        print("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:
    if "##" in s[a-1:c] or "##" in s[b-1:d]:
        print("No")
    else:
        print("Yes")
else:
    if "..." in s[b-2:d+1] and "##" not in s[a-1:c] and "##" not in s[b-1:d]:
        print("Yes")
    else:
        print("No") c < d c d if "##" in s[a-1:c] or "##" in s[b-1:d]:
        print("No")
    else:
        print("Yes") "##" in s[a-1:c] or "##" in s[b-1:d] "##" in s[a-1:c] "##" s[a-1:c] s a-1:c a-1 a 1 c "##" in s[b-1:d] "##" s[b-1:d] s b-1:d b-1 b 1 d print("No") print "No" print("Yes") print "Yes" if "..." in s[b-2:d+1] and "##" not in s[a-1:c] and "##" not in s[b-1:d]:
        print("Yes")
    else:
        print("No") "..." in s[b-2:d+1] and "##" not in s[a-1:c] and "##" not in s[b-1:d] "..." in s[b-2:d+1] and "##" not in s[a-1:c] "..." in s[b-2:d+1] "..." s[b-2:d+1] s b-2:d+1 b-2 b 2 d+1 d 1 "##" not in s[a-1:c] "##" s[a-1:c] s a-1:c a-1 a 1 c "##" not in s[b-1:d] "##" s[b-1:d] s b-1:d b-1 b 1 d print("Yes") print "Yes" print("No") print "No" n, a, b, c, d = map(int, input().split()) map(int, input().split()) n a, b, c, d = map(int, input().split()) map(int, input().split()) a d = map(int, input().split()) map(int, input().split()) d s = input() input() s c, d = map(int, input().split()) map(int, input().split()) c b, c, d = map(int, input().split()) map(int, input().split()) b
n, a, b, c, d = map(int, input().split())

s = input()

if c < d:
    if "##" in s[a-1:c] or "##" in s[b-1:d]:
        print("No")
    else:
        print("Yes")
else:
    if "..." in s[b-2:d+1] and "##" not in s[a-1:c] and "##" not in s[b-1:d]:
        print("Yes")
    else:
        print("No")
