因double精度高于float,故采用double
AC代码如下:
#include <bits/stdc++.h>
int main(){
double t,a;
int n,b;
scanf("%lf%d",&t,&n);
a=t/n;
b=n*2;
printf("%.3lf\n%d\n",a,b);
return 0;
}
因double精度高于float,故采用double
AC代码如下:
#include <bits/stdc++.h>
int main(){
double t,a;
int n,b;
scanf("%lf%d",&t,&n);
a=t/n;
b=n*2;
printf("%.3lf\n%d\n",a,b);
return 0;
}