N = input() cnt = N.count("1") if cnt==2: print("Yes") exit() elif cnt<2: print("No") exit() l = N.find("0") r = N.rfind("1") if l==-1 or r