#include using namespace std; #define rep(i,n) for(int (i) = 0 ; (i) < (int)(n) ; (i)++) #define REP(i,a,b) for(int (i) = a ; (int)(i) <= (int)(b) ; (i)++) #define all(n) (n).begin(),(n).end() typedef vector Vi; typedef vector VVi; typedef pair Pii; typedef vector VPii; int main(){ long long N; cin >> N; int c = 0; for(long long i = 2 ; i*i <= N ; i++){ while( N % i == 0 ){ N /= i; c++; } } if( N != 1 ) c++; if( c >= 3 ){ cout << "YES" << endl; }else{ cout << "NO" << endl; } }