N = int(input()) A = 1 for n in range(2, N+1): A *= 2**n-1 B = 2**(N+1)-1 print("Yes" if A%B == 0 else "No")