#!/usr/bin/env python3 #fileencoding: utf-8 from math import sqrt M = N = int(input()) count = 0 i = 2 while M >= i*i: while N % i == 0: N //= i count += 1 i += 1 if N > 1: count += 1 print("YES" if count >= 3 else "NO")