def main(): n=int(input()) e=1 while n+1 > 10**e: e += 1 if n+1 == 10**e: ans = "Yes" else: ans ="No" print(ans) if __name__ == "__main__": main()