require'prime' r=0 gets.to_i.prime_division.map{|_,a|r+=a} puts r>2?:YES: :NO