This problem is a programming version of Problem 94 from projecteuler.net
It is easily proved that no equilateral triangle exists with integral length sides and integral area. However, the almost equilateral triangle has an area of square units.
We shall define an almost equilateral triangle to be a triangle for which two sides are equal and the third differs by no more than one unit.
Find the sum of the perimeters of all almost equilateral triangles with integral side lengths and area and whose perimeters do not exceed .
First line contains , denoting the number of testcases.
Next lines contains .
Output lines corresponding to test cases.
For first test case we get perimeter .
Second test case there is another triangle whose area is units.