n = int(input()) p = 1 for n in range(2, n + 1): p *= 2 ** n - 1 print('Yes' if p % (2 ** (n + 1) - 1) == 0 else 'No')