結果
| 問題 | No.24 数当てゲーム |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2016-01-08 22:51:33 |
| 言語 | F# (F# 4.0) |
| 結果 |
AC
|
| 実行時間 | 333 ms / 5,000 ms |
| コード長 | 443 bytes |
| コンパイル時間 | 14,308 ms |
| コンパイル使用メモリ | 186,544 KB |
| 実行使用メモリ | 35,272 KB |
| 最終ジャッジ日時 | 2024-09-19 13:12:11 |
| 合計ジャッジ時間 | 18,705 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 10 |
コンパイルメッセージ
復元対象のプロジェクトを決定しています... /home/judge/data/code/main.fsproj を復元しました (403 ms)。 MSBuild のバージョン 17.9.6+a4ecab324 (.NET) main -> /home/judge/data/code/bin/Release/net8.0/main.dll main -> /home/judge/data/code/bin/Release/net8.0/publish/
ソースコード
let ``No.24 数当てゲーム`` () =
let N = int <| stdin.ReadLine()
let s = set [0..9]
let rec f n s =
if n <= 0 then s |> Seq.item 0
else
let arr = stdin.ReadLine().Split(' ')
let s2 = arr.[0..3] |> Array.map int |> Set.ofArray
f (n-1) ((if arr.[4] = "YES" then Set.intersect else Set.difference) s s2)
f N <| set [0..9]
|> printfn "%d"
``No.24 数当てゲーム`` ()