結果

問題 No.668 6.0*10^23
ユーザー tails1434tails1434
提出日時 2020-01-24 07:27:59
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 77 ms / 2,000 ms
コード長 512 bytes
コンパイル時間 418 ms
コンパイル使用メモリ 87,180 KB
実行使用メモリ 71,660 KB
最終ジャッジ日時 2023-10-11 17:20:23
合計ジャッジ時間 6,647 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 73 ms
71,524 KB
testcase_01 AC 76 ms
71,540 KB
testcase_02 AC 75 ms
71,608 KB
testcase_03 AC 74 ms
71,536 KB
testcase_04 AC 74 ms
71,376 KB
testcase_05 AC 75 ms
71,376 KB
testcase_06 AC 74 ms
71,532 KB
testcase_07 AC 74 ms
71,176 KB
testcase_08 AC 74 ms
71,372 KB
testcase_09 AC 75 ms
71,380 KB
testcase_10 AC 74 ms
71,372 KB
testcase_11 AC 76 ms
71,572 KB
testcase_12 AC 76 ms
71,368 KB
testcase_13 AC 76 ms
71,460 KB
testcase_14 AC 75 ms
71,380 KB
testcase_15 AC 74 ms
71,176 KB
testcase_16 AC 73 ms
71,432 KB
testcase_17 AC 74 ms
71,420 KB
testcase_18 AC 74 ms
71,172 KB
testcase_19 AC 75 ms
71,592 KB
testcase_20 AC 76 ms
71,384 KB
testcase_21 AC 76 ms
71,372 KB
testcase_22 AC 76 ms
71,564 KB
testcase_23 AC 75 ms
71,376 KB
testcase_24 AC 75 ms
71,576 KB
testcase_25 AC 74 ms
71,536 KB
testcase_26 AC 75 ms
71,484 KB
testcase_27 AC 75 ms
71,380 KB
testcase_28 AC 76 ms
71,468 KB
testcase_29 AC 76 ms
71,528 KB
testcase_30 AC 76 ms
71,420 KB
testcase_31 AC 76 ms
71,380 KB
testcase_32 AC 77 ms
71,412 KB
testcase_33 AC 76 ms
71,364 KB
testcase_34 AC 76 ms
71,408 KB
testcase_35 AC 74 ms
71,348 KB
testcase_36 AC 76 ms
71,376 KB
testcase_37 AC 75 ms
71,556 KB
testcase_38 AC 75 ms
71,492 KB
testcase_39 AC 75 ms
71,416 KB
testcase_40 AC 75 ms
71,660 KB
testcase_41 AC 76 ms
71,568 KB
testcase_42 AC 74 ms
71,416 KB
testcase_43 AC 76 ms
71,364 KB
testcase_44 AC 76 ms
71,448 KB
testcase_45 AC 75 ms
71,324 KB
testcase_46 AC 74 ms
71,604 KB
testcase_47 AC 75 ms
71,356 KB
testcase_48 AC 72 ms
71,376 KB
testcase_49 AC 74 ms
71,352 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

def custom_round(number, ndigits=0):
    if type(number) == int:
        return number
    d_point = len(str(number).split('.')[1])
    if ndigits >= d_point:
        return number
    c = (10 ** d_point) * 2
    return round((number * c + 1) / c, ndigits)

def main():
    N = input()
    len_N = len(N)
    b = len_N - 1
    a = int(N[:3])
    a /= 100
    a = custom_round(a, 1)
    if a == 10:
        a /= 10
        b += 1

    print(str(a) + '*10^' + str(b))

    



if __name__ == "__main__":
    main()
0