CORN - Corn Headache


 

Once Pandu was eating CORN and enjoying the winter seasion but the shopkeeper has many corns of the of different sizes having Same Price .
Pandu wants the Bigger corn but When he observes all corns he found that many small size Corns have more seeds than Bigger one so He needs your help in chosing the Corn .
As the Corn shape is almost like Cone and You are Good in Mathmatics(Assume you are :P) Pandu wants you to select the Corn for Him and Tell him the Total number of Seeds on this Corn.

Once JHON wanted to eat CORN but the shopkeeper has many corns of different sizes having Same Price .

JHON wants the Bigger corn but When he observes all corns he found that many small size Corns have more seeds than Bigger one so He needs your help in chosing the Corn .

As the Corn shape is almost like Cone and You are Good in Mathmatics(Assume you are :P) JHON wants you to select the Corn for Him and Tell him the Total number of Seeds on this Corn.

 

Input

First line of input is 't' - Test cases.In each of the next t lines There are three Numbers , R- Radius of the Biggest part of Corn and S-The number of Seeds in Corn per 1cm^2 and H-The hight of Corn.This is in the following form

          ReSeH

R,S,H<1000 & Pi=3.1415

Output

Only one Integer i.e. the Number of Seeds on Corn.

Example

Input:
1
2e4e20
Output:
506

hide comments
ansh_08lehri: 2018-12-20 08:43:54

finally solved.learnt a lot.

roopammishra: 2018-10-24 22:49:23

Ac in one go.. But got only 0.2 points

Radha Krishna: 2017-08-09 20:52:09

covered many concepts. :)

pavan_kumar1: 2017-06-22 16:35:47

AC in 0ne g0..... :-)
good concept
0.6 points for me

nermatibhanu: 2017-06-07 11:21:03

very easy problem after separating R,S,H

madhavgaba: 2017-01-16 19:28:30

@author At least mention that r,s,h can be floats too.......read from comments it was so-_-

cs_abhi2000: 2017-01-07 09:09:28

Really interested problem...
New concept...
0.5 points for this problem...

rmaurya: 2016-10-03 20:53:35

no JAVA..WTF!!
Reply: Dear "Jo-bhi-hai" java's split make it easy so no java

Last edit: 2016-10-23 10:51:34
sd_singh: 2016-09-09 15:07:30

please check submission id 17685104. All the test cases of the world are running correctly but still sigsegv fault. PLEASE HELP

Last edit: 2016-09-10 06:16:09
square1001: 2016-07-22 02:02:52

Problem description mistake:
line 5: ... Tell him the Total nuber of Seeds on this Corn.
nuber -> number

(Re) Thank you. Fixed.

Last edit: 2016-07-22 03:15:54

Added by:Losser
Date:2016-02-10
Time limit:0.100s-1s
Source limit:50000B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Languages:All except: ASM64 CSHARP GO GOSU JAVA JS-RHINO JS-MONKEY NICE PHP PYTHON PYPY PYTHON3 PY_NBC RUBY SCALA CHICKEN
Resource:....