char*p,*q,s[200];main(c,t){for(;gets(p=s);printf(c+*q?"failed at: %s\n":"yes\n",c?p-1:"EOL"))for(q=t;c=-~*p++/3,~c%7%3?*q--==c-1:(*++q=c););}