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