T = int(input()) for _ in range(T): N = int(input()) print("Yes" if N in [1, 2, 4, 8, 16] else "No")