题号:NC273394
时间限制:C/C++/Rust/Pascal 1秒,其他语言2秒
空间限制:C/C++/Rust/Pascal 256 M,其他语言512 M
64bit IO Format: %lld
题目描述
A set is called a good set if the sum of any two numbers in the set is not a perfect square.
Given a set

containing

elements, our goal is to partition the set into two non-empty parts

and

(i.e.,

and

) such that both parts

and

in the partition are good sets.
Please determine whether the goal above is achievable for the given set

.
It is guaranteed that elements in set

are all distisnct.
输入描述:
The first line contains a single integer
)
, representing the number of test cases.
The first line of each test case contains a single integer
)
, representing the number of elements in the set

.
The second line of each test case contains

integers
)
, representing the

elements in set

.
输出描述:
For each test case, output "YES" if the goal is achievable, and "NO" otherwise.