8 条题解
-
612317姚玉杨 (12317姚玉杨) LV 7 @ 2021-11-04 12:12:54
#include <iomanip>
#include <iostream>
using namespace std;
int main()
{
double h, r, v;
int n;
cin>>h>>r;
v=r*r*3.1415926*h;
n=int(20000/v);
if (20000/v>0)
{
n++;
cout<< n;
}else {
cout<< n;
}
return 0;
} -
32021-12-27 09:32:10@
#include<iostream>
#include<cmath>
using namespace std;
const double PI=3.14159;
int main(){
int h,r;
cin >> h >> r;
cout<<ceil(20/(PI*r*r*h/1000));
return 0;
} -
22021-12-05 10:16:49@
#include <iomanip>
#include <iostream>
using namespace std;
int main()
{
double h, r, v;
int n;
cin>>h>>r;
v=r*r*3.1415926*h;
n=int(20000/v);
if (20000/v>0)
{
n++;
cout<< n;
}else
{
cout<< n;
}
return 0;
} -
02024-01-31 10:55:43@
#include<bits/stdc++.h>
using namespace std;
int main()
{
int h,r,sum;
double pi=3.14159,v,ml;
cin>>h>>r;
v=pi*r*r*h;
ml=v;
sum=ceil(20000/ml);
cout<<sum;
return 0;
} -
02021-10-17 12:36:28@
#include<bits/stdc++.h>
#define db double
using namespace std;
int main()
{
const double Pi=3.14159;
int a,h,r;
cin>>h>>r;
int cnt=0;
int sum=0;
while(sum<=20000)
{
sum+=Pi*r*r*h;
cnt++;
}
printf("%d",cnt);
return 0;
} -
-12021-12-31 16:19:54@
#include<bits/stdc++.h>
#define db double
using namespace std;
const db pi=3.14159;
int main(){
db h,r;cin>>h>>r;
int cnt=0;
db sum=0;
while(sum<=20000){
sum+=pi*r*r*h;
cnt++;
}
printf("%d",cnt);
return 0;
} -
-12021-11-21 21:12:02@
#include <iostream>
#include <cmath>
using namespace std;
int main()
{
int h,r;
cin>>h>>r;
cout<<ceil(20*1000/(3.14159*r*r*h))<<endl;
return 0;
} -
-82021-04-28 22:00:24@
#include<bits/stdc++.h> #define db double using namespace std; const db pi=3.14159; int main(){ db h,r;cin>>h>>r; int cnt=0; db sum=0; while(sum<=20000){ sum+=pi*r*r*h; cnt++; } printf("%d",cnt); return 0; }
- 1
信息
- ID
- 1000
- 难度
- 7
- 分类
- (无)
- 标签
- 递交数
- 1361
- 已通过
- 236
- 通过率
- 17%
- 被复制
- 25
- 上传者