You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
402 B
17 lines
402 B
#include <bits/stdc++.h>
|
|
|
|
using namespace std;
|
|
|
|
int main() {
|
|
ios::sync_with_stdio(false); //读入输出优化的强迫症
|
|
int a, b, c;
|
|
while (true) {
|
|
cin >> a >> b >> c;
|
|
//设置输出为小数点后c位
|
|
cout << fixed << setprecision(c);
|
|
if (a == 0 && b == 0 && c == 0) break;
|
|
double d = 1.0 * a / b;
|
|
cout << d << endl;
|
|
}
|
|
return 0;
|
|
} |