Accept a number X as the input. The program must print YES if it is greater than 3 and less than 10. Else print NO as the output using logical AND.
Example Input/Output 1:
Input:
5
Output:
YES
Example Input/Output 2:
Input:
19
Output:
NO
#include <stdio.h>
int main()
{
int X;
scanf("%d", &X);
printf((X > 3 && X < 10) ? "YES" : "NO");
return 0;
}