F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

Problem K. Harbin Sausage

Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 262144/262144 K (Java/Others)
Total Submission(s): 1655    Accepted Submission(s): 688


Problem Description
Harbin Sausage is a kind of food usually made from ground meat, such as pork, beef along with salt and spices. The sausage has a history of over 100 years. Because the surface color of it is date red, people call it red sausage or Harbin sausage.
Harbin Sausage is reputable all over the country; it has now become the daily necessity for Harbin people to welcome friends and guests. The procedure is a little bit complicated. First, season the meat and put it in fridge for two or three days. Second, stir the meat with starch till it becomes meatballs. Third, fill the meat into the casing with special tools. Fourth, put it into a toaster oven for 1 hour at most. But the finished product is tasty. You can eat it directly, or match it with other dishes and Harbin beer.
(The above is quoted from http://www.chinatours.com/travel-guide/harbin/food/harbin-sausage.html)
A sausage can be regarded as a cylinder(圆柱体) attached with a hemisphere(半球) in each ends. The height of the cylinder is H, and the radius of both the cylinder and the hemispheres is R. You can see the following three views(三视图) to get a better understanding:

Now you are going to buy a sausage in the Mysterious Sausage Store. Given H and R (both are integers),please calculate how much you should pay. For convenience, the price of per unit volume(单位体积) is set to be 3/Pi(圆周率), and thus the answer is obviously a integer.
 

Input
One line containing H and R, 1 ≤ H, R ≤ 100
 

Output
One line containing the amount of money you should pay for this sausage
 

Sample Input
5 6
 

Sample Output
1404
 

Source
 

Statistic | Submit | Discuss | Note
Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-05-05 08:19:38, Gzip enabled