結果

問題 No.164 ちっちゃくないよ!!
ユーザー pekempeypekempey
提出日時 2015-12-20 16:46:27
言語 Python2
(2.7.18)
結果
AC  
実行時間 31 ms / 2,000 ms
コード長 316 bytes
コンパイル時間 836 ms
コンパイル使用メモリ 6,572 KB
実行使用メモリ 6,136 KB
最終ジャッジ日時 2023-08-04 16:15:41
合計ジャッジ時間 1,645 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 11 ms
6,080 KB
testcase_01 AC 11 ms
6,136 KB
testcase_02 AC 12 ms
6,048 KB
testcase_03 AC 12 ms
5,948 KB
testcase_04 AC 12 ms
6,136 KB
testcase_05 AC 31 ms
6,068 KB
testcase_06 AC 24 ms
5,988 KB
testcase_07 AC 17 ms
6,024 KB
testcase_08 AC 20 ms
6,088 KB
testcase_09 AC 20 ms
5,988 KB
testcase_10 AC 12 ms
6,036 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

s = map(chr, range(ord('0'), ord('9') + 1) + range(ord('A'), ord('Z') + 1))

n = input()
v = [raw_input() for _ in xrange(n)]

ans = float('inf')
for i in xrange(n):
    val = 0
    base = max([s.index(c) for c in v[i]]) + 1
    for c in v[i]:
        val = val * base + s.index(c)
    ans = min(ans, val)
print ans
0