for _ in range(int(input())): n = int(input()) print('Yes' if n in (1, 2, 4, 8, 16) else 'No')