1241: 寻找数字

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

Description

小杨有一个正整数 a,小杨想知道是否存在一个正整数 b 满足 a=b4



Input

第一行包含一个正整数 t,代表测试数据组数。 对于每组测试数据,第一行包含一个正整数代表 a。

Output

对于每组测试数据,如果存在满足条件的正整数 b,则输出 b,否则输出 −1。

Sample Input Copy

3
16
81
10

Sample Output Copy

2
3
-1

HINT

数据范围与提示

对于全部数据,保证有 1 ≤ t ≤ 105,1≤ ai ≤108