N, A, B, C, D = map(int, input().split())
S = input()

for i in range(A, max(C, D)):
    if S[i-1:i+1] == '##':
        print('No')
        exit(0)

if C < D:
    print('Yes')
    exit(0)

for i in range(B-1, D):
    if S[i-1:i+2] == '...':
        print('Yes')
        exit(0)
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 for i in range(A, max(C, D)):
    if S[i-1:i+1] == '##':
        print('No')
        exit(0) i range(A, max(C, D)) range A max(C, D) max C D if S[i-1:i+1] == '##':
        print('No')
        exit(0) S[i-1:i+1] == '##' S[i-1:i+1] S i-1:i+1 i-1 i 1 i+1 i 1 '##' print('No') print 'No' exit(0) exit 0 if C < D:
    print('Yes')
    exit(0) C < D C D print('Yes') print 'Yes' exit(0) exit 0 for i in range(B-1, D):
    if S[i-1:i+2] == '...':
        print('Yes')
        exit(0) i range(B-1, D) range B-1 B 1 D if S[i-1:i+2] == '...':
        print('Yes')
        exit(0) S[i-1:i+2] == '...' S[i-1:i+2] S i-1:i+2 i-1 i 1 i+2 i 2 '...' print('Yes') print 'Yes' exit(0) exit 0 print('No') print 'No' S = input() input() S N, A, B, C, D = map(int, input().split()) map(int, input().split()) N D = map(int, input().split()) map(int, input().split()) D A, B, C, D = map(int, input().split()) map(int, input().split()) A B, C, D = map(int, input().split()) map(int, input().split()) B C, D = map(int, input().split()) map(int, input().split()) C
N, A, B, C, D = map(int, input().split())
S = input()

for i in range(A, max(C, D)):
    if S[i-1:i+1] == '##':
        print('No')
        exit(0)

if C < D:
    print('Yes')
    exit(0)

for i in range(B-1, D):
    if S[i-1:i+2] == '...':
        print('Yes')
        exit(0)
print('No')
