q = input()
a=0
for i in q :
	if i == 'x' : a+=1

if a>=8 : print("NO") 
else : print("YES") q = input() q input() input a=0 a 0 for i in q :
	if i == 'x' : a+=1 i q if i == 'x' : a+= i == 'x' i 'x' if a>=8 : print("NO") 
else : print("YES") a>=8 a 8 a=0 0 a q = input() input() q
q = input()
a=0
for i in q :
	if i == 'x' : a+=1

if a>=8 : print("NO") 
else : print("YES")