logo AlgoBeat OnlineJudge
登录 注册

#216959. [ICPC 2017 Qingdao R] Pythagoras, One More Time

内存限制:512 MiB 时间限制:14000 ms 标准输入输出
题目类型:VJudge(洛谷) 评测方式:VJudge
上传者: 匿名

题目描述

“Pythagoras, One More Time” triples over are all solutions of where , and are constrained to be positive integers less than or equal to .

You are to calculate the number of the triples such that .

输入格式

The first line is an integer () indicating the total number of cases. For each test case a line contains the integer ().

输出格式

For each case output the total number of triples in a line.

样例

样例输入 1

10
1
2
3
4
5
6
7
8
9
10

样例输出 1

0
0
1
1
2
3
3
3
4
4