Obtain the volume of the Cone |
Difficulty level: A; running time limit: 1000 ms; running space limit: KB; code length limit: B |
Question description |
The radius R and H of the bottom side of the input cone (both do not exceed 50), and the volume V of the cone is output. |
Input |
Two numbers R and H are separated by a space. |
Output |
One number, V |
Input example |
3 7 |
Output example |
65.94 |
Other Instructions |
Note: The bottom of the cone is a circle. The volume of the cone is equal to the bottom area of the cone multiplied by the height and divided by 3. Here, the circumference rate is 3.14 When the area of the circle is calculated, and the variables used use the double type. |
The cone volume is 1/3 of the height of the same bottom column.
Directly add the code.
The Code is as follows:
# Include <iostream> # include <cmath> using namespace STD; int main () {double A, B; CIN> A> B; cout <3.14 * a * B/3 <Endl; return 0 ;}
0020 --- obtain the cone volume