結果
問題 |
No.668 6.0*10^23
|
ユーザー |
|
提出日時 | 2018-05-03 21:19:12 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 521 bytes |
コンパイル時間 | 1,696 ms |
コンパイル使用メモリ | 159,024 KB |
実行使用メモリ | 6,944 KB |
最終ジャッジ日時 | 2024-06-30 06:30:54 |
合計ジャッジ時間 | 3,006 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 47 WA * 3 |
ソースコード
#include "bits/stdc++.h" #define fastcin {\ cin.tie(0);\ ios::sync_with_stdio(false);\ } using namespace std; int main() { fastcin; string n; cin >> n; for(int i = n.length()-1; i > 1; i--) { if(n[i] > '4') { n[i-1]++; } n[i] = '0'; } if(n[1]==':') { n[1] = '0'; n[0]++; } if(n[0]==':') { cout << "1.0*10^" << n.length() << '\n'; } else cout << n[0] << "." << n[1] << "*10^" << n.length()-1 << '\n'; return 0; }