地址
http://acm.hdu.edu.cn/showproblem.php?pid=2002
定位
数学题
水题
分析
-
V=43πr3
代码
- #include <iostream>
- #include <math.h>
- #include <stdio.h>
- #include <string.h>
- #define PI 3.1415927
- using namespace std;
- int main() {
- double r;
- while(scanf(“%lf”,&r)!=EOF) {
- double tmp=PI*pow(r,3)*4/3;
- printf(”%.3lf\n”,tmp);
- }
- return 0;
- }
性能
Exe.Time | Exe.Memory | Code Length | Language |
---|---|---|---|
0MS | 1872K | 287B | c++ |