N, A, B, C, D = map(int, input().split())
S = input()
print('No' if '##' in S[A:C-1] or '##' in S[B:D-1] or C == D or C > D and '...' not in S[B-2:D+1] else 'Yes') 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 print('No' if '##' in S[A:C-1] or '##' in S[B:D-1] or C == D or C > D and '...' not in S[B-2:D+1] else 'Yes') print 'No' if '##' in S[A:C-1] or '##' in S[B:D-1] or C == D or C > D and '...' not in S[B-2:D+1] else 'Yes' '##' in S[A:C-1] or '##' in S[B:D-1] or C == D or C > D and '...' not in S[B-2:D+1] '##' in S[A:C-1] or '##' in S[B:D-1] or C == D '##' in S[A:C-1] or '##' in S[B:D-1] '##' in S[A:C-1] '##' S[A:C-1] S A:C-1 A C-1 C 1 '##' in S[B:D-1] '##' S[B:D-1] S B:D-1 B D-1 D 1 C == D C D C > D and '...' not in S[B-2:D+1] C > D C D '...' not in S[B-2:D+1] '...' S[B-2:D+1] S B-2:D+1 B-2 B 2 D+1 D 1 'No' 'Yes' C, D = map(int, input().split()) map(int, input().split()) C S = input() input() S B, C, D = map(int, input().split()) map(int, input().split()) B 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
N, A, B, C, D = map(int, input().split())
S = input()
print('No' if '##' in S[A:C-1] or '##' in S[B:D-1] or C == D or C > D and '...' not in S[B-2:D+1] else 'Yes')
