s=list(input()) #print(s) if set(s[1::2])=={" "} and "".join(s[::2]) not in " ": print("Yes") else: print("No")