結果

問題 No.722 100×100=1000
ユーザー Yuhel Tanaka
提出日時 2018-10-09 15:05:05
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 33 ms / 2,000 ms
コード長 299 bytes
コンパイル時間 513 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 10,752 KB
最終ジャッジ日時 2024-12-29 19:39:40
合計ジャッジ時間 2,163 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 27
権限があれば一括ダウンロードができます

ソースコード

diff #

def f(n):
  if n==0:return 0
  c=0
  while n%10==0:
    c+=1
    n//=10
  return c

a,b=map(int,input().split())
c,d=f(a),f(b)
e,f=a//(10**c),b//(10**d)

if 1<=abs(e)<=9 and 1<=abs(f)<=9 and c>=2 and d>=2:
  print(a*b//10)
else:
  res=a*b
  if abs(res)<10**8:
    print(res)
  else:
    print("E")

0