MAXLN

In this problem you will be given a half-circle. The half-circle’s radius is r. You can take any point A on the half-circle and draw 2 lines from the point to the two sides of the diameter(AB and AC). Let the sum of square of one line’s length and the other line’s length is s.

Illustration

Like in the figure s=AB^2+AC. And BC=2r.

Now given r you have to find the maximum value of s. That is you have to find point A such that AB^2+AC is maximum.

Input:

First line of the test case will be the number of test case T(1<=T<=1000) . Then T lines follows. On each line you will find a integer number r(1<=r<=1000000); each representing the radius of the half-circle.

Output:

For each input line, print a line containing “Case I: ”, where I is the test case number and the maximum value of s. Print 2 digit after decimal(Errors should be less then .01).

Example

Input:
1
1

Output:
Case 1: 4.25


#include <iostream>
#include <iomanip>

using namespace std;

int main() {  
    int T;
    cin >> T;
    for (int t = 1; t <= T; ++t) {
        double n;
        cin >> n;
        cout << "Case " << setprecision(2) << fixed 
             << t << ": " << 4*n*n+0.25 << "\n";
    }
    return 0;
}