April Fools' Day Contest 2 P1 - Columbus' Conjecting Conundrum

View as PDF

Submit solution


Points: 0
Time limit: 2.0s
Memory limit: 256M

Author:
Problem type

Concurrent with Columbus' colonialism contract, Cambodia's consumerism consultant commissions Columbus with contemplating compelling conspiracies contingent with a certain celebrated Conjecture.

Given n candidate cardinals c1cn, Columbus is compulsed to conclude whether circular composition of C(ci) where C(c)={3c+1c2c2c|2 causes convergence to 1.

Can you capitalize on the compute capacity of Columbus' computer's CPU cores to complete this ceaseless chore?

Input Specification

The first line contains one integer n (1n106). The second line contains n space separated integers ci (1ci109).

Output Specification

Print n lines, YES if the circular composition of C(ci) converges to 1, NO if it doesn't.

Sample Input

Copy
2
2 3

Sample Output

Copy
YES
YES

Comments

There are no comments at the moment.