#include <stdio.h>

int main()
{
    int a;
    scanf("%d",&a);
    int b=a/10;
    int c=a%10;
    if (b==9)
        printf("Yes\n");
    else if (c==9)
        printf("Yes\n");
    else
        printf("No\n");
    return 0;
}
