結果
問題 | No.164 ちっちゃくないよ!! |
ユーザー | aimy |
提出日時 | 2017-04-25 11:11:23 |
言語 | Haskell (9.8.2) |
結果 |
AC
|
実行時間 | 7 ms / 2,000 ms |
コード長 | 290 bytes |
コンパイル時間 | 658 ms |
コンパイル使用メモリ | 165,408 KB |
実行使用メモリ | 10,904 KB |
最終ジャッジ日時 | 2023-10-11 09:15:54 |
合計ジャッジ時間 | 1,611 ms |
ジャッジサーバーID (参考情報) |
judge13 / judge14 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 2 ms
6,812 KB |
testcase_01 | AC | 2 ms
6,812 KB |
testcase_02 | AC | 2 ms
6,864 KB |
testcase_03 | AC | 2 ms
6,880 KB |
testcase_04 | AC | 2 ms
6,880 KB |
testcase_05 | AC | 6 ms
10,904 KB |
testcase_06 | AC | 7 ms
10,868 KB |
testcase_07 | AC | 5 ms
9,876 KB |
testcase_08 | AC | 6 ms
10,832 KB |
testcase_09 | AC | 6 ms
10,800 KB |
testcase_10 | AC | 3 ms
7,144 KB |
コンパイルメッセージ
Loaded package environment from /home/judge/.ghc/x86_64-linux-9.6.1/environments/default [1 of 2] Compiling Main ( Main.hs, Main.o ) [2 of 2] Linking a.out
ソースコード
import Data.Char import Data.List main = getContents >>= print . dmin . tail . words dec c = if isDigit c then digitToInt c else ord c - 55 dmin = minimum . map toDecimal toDecimal d = sum $ zipWith (*) (iterate (*r) 1) (reverse (map dec d)) where r = dec (head (reverse (sort d))) + 1