公式
A - Water Pressure 解説 by en_translator
If you are new to learning programming and do not know where to start, please try Problem A “Welcome to AtCoder” from practice contest. There you can find a sample code for each language.
Receive the input, multiply it by \(0.01\), and output it.
Note that the answer may be a decimal, so the values have to be computed as decimal numbers.
Sample code (C++)
#include <bits/stdc++.h>
using namespace std;
int main(){
double a; cin >> a;
cout << a / 100 << endl;
}
Sample code 2 (C++)
#include <bits/stdc++.h>
using namespace std;
int main(){
double a; cin >> a;
cout << a * 0.01 << endl;
}
An example of wrong answer (C++)
#include <bits/stdc++.h>
using namespace std;
int main(){
int a; cin >> a;
cout << a / 100 << endl; // For example, if a = 350, it mistakenly outputs 3
}
投稿日時:
最終更新: