結果
| 問題 | 
                            No.668 6.0*10^23
                             | 
                    
| コンテスト | |
| ユーザー | 
                             tnakao0123
                         | 
                    
| 提出日時 | 2018-03-25 00:38:28 | 
| 言語 | C++11(廃止可能性あり)  (gcc 13.3.0)  | 
                    
| 結果 | 
                             
                                AC
                                 
                             
                            
                         | 
                    
| 実行時間 | 3 ms / 2,000 ms | 
| コード長 | 734 bytes | 
| コンパイル時間 | 619 ms | 
| コンパイル使用メモリ | 84,948 KB | 
| 実行使用メモリ | 6,944 KB | 
| 最終ジャッジ日時 | 2024-06-30 05:36:30 | 
| 合計ジャッジ時間 | 2,051 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge2 / judge5 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | AC * 50 | 
ソースコード
/* -*- coding: utf-8 -*-
 *
 * 668.cc: No.668 6.0*10^23 - yukicoder
 */
#include<cstdio>
#include<cstdlib>
#include<cstring>
#include<cmath>
#include<iostream>
#include<string>
#include<vector>
#include<map>
#include<set>
#include<stack>
#include<list>
#include<queue>
#include<deque>
#include<algorithm>
#include<numeric>
#include<utility>
#include<complex>
#include<functional>
 
using namespace std;
/* constant */
/* typedef */
/* global variables */
/* subroutines */
/* main */
int main() {
  string s;
  cin >> s;
  int c = s.size();
  int ab = (s[0] - '0') * 10 + (s[1] - '0');
  if (s[2] >= '5') ab++;
  if (ab >= 100) printf("1.0*10^%d\n", c);
  else printf("%d.%d*10^%d\n", ab / 10, ab % 10, c - 1);
  return 0;
}
            
            
            
        
            
tnakao0123