結果
問題 | No.1217 せしすせそ |
ユーザー |
|
提出日時 | 2021-06-01 21:36:26 |
言語 | OCaml (5.2.1) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 451 bytes |
コンパイル時間 | 464 ms |
コンパイル使用メモリ | 19,564 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-11-09 00:17:20 |
合計ジャッジ時間 | 1,012 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 10 |
ソースコード
let string_1_list_of_string x =String.to_seq x|> List.of_seq|> List.map (String.make 1);;let hikaku = string_1_list_of_string "abcdefghijklmnopqrstuvwxyz";;let rec check lst lst2 =let c1 = List.hd lst inlet c2 = List.hd lst2 inif (c1 <> c2) then (c1 ^ "to" ^ c2)else check (List.tl lst) (List.tl lst2);;let () =let test = read_line () |> string_1_list_of_string incheck hikaku test |> print_string; print_newline ();;