結果
問題 | No.289 数字を全て足そう |
ユーザー |
|
提出日時 | 2017-05-14 05:42:58 |
言語 | Haskell (9.10.1) |
結果 |
AC
|
実行時間 | 13 ms / 1,000 ms |
コード長 | 220 bytes |
コンパイル時間 | 4,338 ms |
コンパイル使用メモリ | 174,976 KB |
実行使用メモリ | 8,320 KB |
最終ジャッジ日時 | 2024-09-15 13:03:57 |
合計ジャッジ時間 | 2,565 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 21 |
コンパイルメッセージ
Loaded package environment from /home/judge/.ghc/x86_64-linux-9.8.2/environments/default [1 of 2] Compiling Main ( Main.hs, Main.o ) [2 of 2] Linking a.out
ソースコード
import Data.Char (isDigit) readDigits :: IO [Int] readDigits = map read <$> words <$> getLine main :: IO () main = do line <- getLine let x = [read [c] | c<-line, isDigit c] :: [Int] putStrLn . show $ sum x