import java.math.BigInteger; import java.util.Arrays; import java.util.LinkedList; import java.util.Scanner; public class Main { public static void main(String[] args){ Scanner sc = new Scanner(System.in); final long N = sc.nextLong(); if(N == 1){ System.out.println("NO"); return; } final int sqrt_N = (int)(Math.floor(Math.sqrt(N))); long cur_N = N; int types = 0, max_counts = 0; for(int i = 2; i <= sqrt_N; i++){ int count = 0; while(cur_N % i == 0){ count++; cur_N /= i; } max_counts = Math.max(max_counts, count); if(count != 0){ types++; } } if(cur_N != 1){ types++; } //System.out.println(cur_N + " " + types + " " + max_counts); if((types >= 3 || max_counts >= 3 || (types >= 2 && max_counts >= 2))){ System.out.println("YES"); }else{ System.out.println("NO"); } } }