結果
問題 |
No.9011 数字を全て足そう(数字だけ)
|
ユーザー |
![]() |
提出日時 | 2020-04-02 01:26:36 |
言語 | OCaml (5.2.1) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 254 bytes |
コンパイル時間 | 359 ms |
コンパイル使用メモリ | 19,688 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-10-09 00:53:22 |
合計ジャッジ時間 | 1,340 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 23 |
ソースコード
let () = let s = read_line () in let len = String.length s in let rec f acc i = if i >= len then acc else let n = int_of_string @@ Char.escaped s.[i] in f (acc + n) (i + 1) in print_int @@ f 0 0