N = list(input()) for i in range(len(N)): if N[i] != '9': exit(print("No")) print("Yes")