#include #include #include char str[60000]; int str_len = 0; /// /// 入力された数字を返す /// /// int ReadNum() { int negate = 0; char c = getchar(); int num = 0; int numCnt = 0; while (c != '\n') { if (c == '-') { negate = 1; } else { num = num * 10 + c - '0'; } c = getchar(); } if (negate == 1) { num *= -1; } return num; } int isPrime(uint64_t num) { for (uint64_t i = 2;i < num;i++) { if (num % i == 0) return 0; } return 1; } int isUseful(uint64_t num) { for (uint64_t i = 2;i < num;i++) { if (isPrime(i)); if (num % i == 0) return 1; } return 0; } int main() { int num = ReadNum(); if (isUseful(num)) { printf("YES\n"); } else { printf("NO\n"); } }