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

a -= 1
b -= 1
c -= 1
d -= 1

if '##' in s[a:max(c,d)+1]:
    print('No')
    exit()

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

a -= 1
b -= 1
c -= 1
d -= 1

if '##' in s[a:max(c,d)+1]:
    print('No')
    exit()

if c < d:
    print('Yes')
else:
    if '...' in s[b-1:d+2]:
        print('Yes')
    else:
        print('No')