3237: 平方之和(GESP二级)

Memory Limit:128 MB Time Limit:1.000 S
Judge Style:Text Compare Creator:
Submit:1 Solved:1

Description

小杨有 n 个正整数 a₁, a₂, ... ,aₙ,他想知道对于所有的 i(1≤i≤n),是否存在两个正整数 x 和 y 满足 x*x + y*y = aᵢ 。

Input

第一行包含一个正整数 n,代表正整数数量。

之后 n 行,每行包含一个正整数,代表 aᵢ 。


0≤n≤10 ,1≤aᵢ≤10⁶

Output

对于每个正整数 aᵢ ,如果存在两个正整数 x 和 y 满足 x*x + y*y = aᵢ ,输出 Yes,否则输出 No。

Sample Input Copy

2
5
4

Sample Output Copy

Yes
No