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