結果

問題 No.722 100×100=1000
ユーザー convexineqconvexineq
提出日時 2021-02-26 02:13:45
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 73 ms / 2,000 ms
コード長 395 bytes
コンパイル時間 339 ms
コンパイル使用メモリ 87,068 KB
実行使用メモリ 71,532 KB
最終ジャッジ日時 2023-08-28 16:03:32
合計ジャッジ時間 3,885 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 72 ms
71,420 KB
testcase_01 AC 71 ms
71,316 KB
testcase_02 AC 72 ms
71,408 KB
testcase_03 AC 72 ms
71,300 KB
testcase_04 AC 73 ms
71,344 KB
testcase_05 AC 72 ms
71,072 KB
testcase_06 AC 72 ms
71,344 KB
testcase_07 AC 72 ms
71,416 KB
testcase_08 AC 72 ms
71,316 KB
testcase_09 AC 71 ms
71,068 KB
testcase_10 AC 72 ms
71,348 KB
testcase_11 AC 71 ms
71,132 KB
testcase_12 AC 70 ms
71,388 KB
testcase_13 AC 72 ms
71,236 KB
testcase_14 AC 71 ms
71,320 KB
testcase_15 AC 72 ms
71,136 KB
testcase_16 AC 71 ms
71,204 KB
testcase_17 AC 72 ms
71,328 KB
testcase_18 AC 73 ms
71,136 KB
testcase_19 AC 72 ms
71,364 KB
testcase_20 AC 72 ms
71,284 KB
testcase_21 AC 72 ms
71,068 KB
testcase_22 AC 72 ms
71,484 KB
testcase_23 AC 71 ms
71,532 KB
testcase_24 AC 73 ms
71,044 KB
testcase_25 AC 72 ms
71,316 KB
testcase_26 AC 73 ms
71,360 KB
testcase_27 AC 72 ms
71,336 KB
testcase_28 AC 73 ms
71,428 KB
testcase_29 AC 73 ms
71,072 KB
testcase_30 AC 72 ms
71,408 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

def is10(x):
    c = 0
    while x%10==0:
        x //= 10
        c += 1
    if abs(x) <= 9 and c >= 2:
        return (c,x)
    else:
        return (-1,-1)

A,B = map(int,input().split())
if A==0 or B==0:
    print(0)
    exit()
n,a = is10(A)
m,b = is10(B)
if n >= 2 and m >= 2:
    print(a*b*10**(n+m-1))
else:
    x = A*B
    if abs(x) < 10**8:
        print(x)
    else:
        print("E")
0