結果

問題 No.164 ちっちゃくないよ!!
ユーザー 小指が強い人小指が強い人
提出日時 2015-11-23 13:41:01
言語 Ruby
(3.2.2)
結果
AC  
実行時間 90 ms / 2,000 ms
コード長 327 bytes
コンパイル時間 252 ms
コンパイル使用メモリ 11,396 KB
実行使用メモリ 15,400 KB
最終ジャッジ日時 2023-08-04 16:15:28
合計ジャッジ時間 2,050 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 84 ms
15,064 KB
testcase_01 AC 81 ms
15,308 KB
testcase_02 AC 81 ms
15,092 KB
testcase_03 AC 84 ms
15,120 KB
testcase_04 AC 83 ms
15,172 KB
testcase_05 AC 90 ms
15,400 KB
testcase_06 AC 89 ms
15,280 KB
testcase_07 AC 85 ms
15,280 KB
testcase_08 AC 86 ms
15,204 KB
testcase_09 AC 86 ms
15,380 KB
testcase_10 AC 81 ms
15,168 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

n = gets.to_i
a = Array.new
n.times do
    s = gets
    max_c = "1"
    s.each_char do |x|
        max_c = x if x.ord > max_c.ord
    end
    base = 2
    if max_c.ord >= "1".ord && max_c.ord <= "9".ord
        base = max_c.ord - 48 + 1
    else
        base = max_c.ord - 55 + 1
    end
    a.push(s.to_i(base))
end
puts a.min
0