結果

問題 No.164 ちっちゃくないよ!!
ユーザー あかりきあかりき
提出日時 2021-03-01 18:41:25
言語 PyPy3
(7.3.13)
結果
AC  
実行時間 104 ms / 2,000 ms
コード長 327 bytes
コンパイル時間 1,236 ms
コンパイル使用メモリ 86,576 KB
実行使用メモリ 76,812 KB
最終ジャッジ日時 2023-07-26 13:45:42
合計ジャッジ時間 2,269 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 74 ms
71,188 KB
testcase_01 AC 74 ms
71,136 KB
testcase_02 AC 75 ms
71,116 KB
testcase_03 AC 74 ms
70,908 KB
testcase_04 AC 76 ms
71,132 KB
testcase_05 AC 104 ms
76,444 KB
testcase_06 AC 99 ms
76,812 KB
testcase_07 AC 92 ms
76,184 KB
testcase_08 AC 98 ms
76,512 KB
testcase_09 AC 98 ms
76,544 KB
testcase_10 AC 77 ms
71,284 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n=int(input())
v=[list(input()) for i in range(n)]

c=[chr(i) for i in range(65, 65+26)]
l=[str(i) for i in range(10)]+c

ans=[]
for i in range(n):
  x=v[i]
  y=-1
  for j in range(len(x)):
    y=max(y,l.index(x[j]))
  y+=1
  x.reverse()
  z=0
  for j in range(len(x)):
    z+=l.index(x[j])*y**j
  ans.append(z)
print(min(ans))
0