MohamedA95 / Eating_pizza

problem #H solution from NC3 competition

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Eating_pizza

problem #H solution from NC3 competition

Problem H. Eating Pizza

Program: pizza. (cpp | java) Input: pizza.in Balloon Color:red

Youssef Alaoui isn’t only good in organizing pool side dinners but also at making pizza, but since he is

a very creative person, he doesn’t like the conventional shape of pizza, and he prefers to make it in a triangular shape, rather than a circular one.

He wanted to serve pizza for the poolside dinner, and since the number of world finals attendees is huge, he needed to make big amounts of triangular-shaped pizzas, but he only has a circular tray, so he decided to make the maximum triangle shaped pizza that can be made using the circular tray. Given the area of the resulting maximum triangle, can you find out the area of the circle?

Input

The first line of the input contains an integer T (1 < T < 10^6), the number of test cases. Each test case contains only one number A (1 < A < 10^6), the area of the resulting triangle.

Output

For each test case print a single number, the area of the circle with relative error up to 1e-6. Examples

Standard input----->Standard output 3 1------------------->2 . 418399 3------------------->7 . 255197 27------------------>65 . 296777

About

problem #H solution from NC3 competition


Languages

Language:Java 100.0%