N=int(input())
print("YES" if N>ord("y")%ord("<") and all(N%i for i in range(ord("z")%ord("<"),N)) else "NO")