Yaoyanni @ 2023-08-24 10:17:57
6,8,9,11,12,13,14过不了
#include <stdio.h>
#include <math.h>
int main() {
int A=0;
scanf("%d",&A);
if (A == 1) {
printf("I love Luogu!");
} else if (A == 2) {
printf("6 4");
} else if (A == 3) {
int d=14,e=4;
printf("%d\n%d\n%d\n",d/e,d/e*4,d%e);
} else if (A == 4) {
double f=500,g=3,h;
h=f/g;
printf("%.6g",h);
} else if (A == 5) {
int k;
k=480/32;
printf("%d",k);
} else if (A == 6) {
int l;
l=sqrt(6*6+9*9);
printf("%d",l);
} else if (A == 7) {
int m,n;
m=110;
n=90;
printf("%d\n%d\n0\n",m,n);
} else if (A == 8) {
double p,q,r,s=3.141593;
p=2*s*5;
q=5*5*s;
r=5*5*5*s*4/3;
printf("%lf\n%lf\n%lf\n",p,q,r);
} else if (A == 9) {
printf("26");
} else if (A== 10) {
printf("9");
} else if (A== 11) {
double x;
x=100/(8-5);
printf("%lf",x);
} else if (A == 12) {
printf("13\n""r");
} else if (A == 13) {
double y,s=3.141593;
y=4/3*s*(4*4*4+10*10*10);
printf("%lf",y);
} else if (A == 14) {
int price=110,people=10;
double sum;
sum=price*people;
while(sum<3500){
price--;
people++;
}
if(sum>=3500){
sum=round(sum*10000);
printf("%.4g",price*people);
}
}
return 0;
}
by FurippuWRY @ 2024-02-19 13:17:24
@zhongdongyifan
啥,先打了
using namespace std;
或一些别的语句才不用写 std::