It is September 9 in Japan now.  You are given a two-digit integer N. Answer the question: Is 9 contained in the decimal notation of N?
a=input()
print('YES'if '9'in a else 'NO')
a=input()
print('Yes'if '9'in a else 'No')