#include<stdio.h>
#include<math.h>
int main()
{
	int n;
	scanf("%d",&n);
	if(n%10==9)
	{
		printf("YES\n");
		printf("The one's digit of %d is 9.",n);
	}
	else if(n/10==9){
		printf("YES");
	
	}
	else{
		printf("NO\n");
		printf("%d does not contain 9",n);
	}
	return 0;
}