結果

問題 No.349 干支の置き物
ユーザー ichibanshiboriichibanshibori
提出日時 2016-04-29 19:10:56
言語 F#
(F# 4.0)
結果
AC  
実行時間 87 ms / 2,000 ms
コード長 402 bytes
コンパイル時間 15,156 ms
コンパイル使用メモリ 185,544 KB
実行使用メモリ 32,000 KB
最終ジャッジ日時 2024-04-28 14:47:26
合計ジャッジ時間 11,941 ms
ジャッジサーバーID
(参考情報)
judge2 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 83 ms
31,616 KB
testcase_01 AC 79 ms
31,724 KB
testcase_02 AC 81 ms
31,872 KB
testcase_03 AC 80 ms
31,488 KB
testcase_04 AC 80 ms
31,488 KB
testcase_05 AC 81 ms
31,744 KB
testcase_06 AC 79 ms
31,744 KB
testcase_07 AC 77 ms
31,732 KB
testcase_08 AC 82 ms
31,616 KB
testcase_09 AC 80 ms
31,616 KB
testcase_10 AC 85 ms
31,844 KB
testcase_11 AC 81 ms
31,872 KB
testcase_12 AC 84 ms
31,712 KB
testcase_13 AC 80 ms
31,488 KB
testcase_14 AC 74 ms
31,744 KB
testcase_15 AC 79 ms
31,744 KB
testcase_16 AC 78 ms
31,488 KB
testcase_17 AC 75 ms
31,488 KB
testcase_18 AC 76 ms
31,480 KB
testcase_19 AC 82 ms
31,616 KB
testcase_20 AC 87 ms
31,616 KB
testcase_21 AC 86 ms
31,616 KB
testcase_22 AC 83 ms
31,744 KB
testcase_23 AC 80 ms
31,740 KB
testcase_24 AC 79 ms
31,616 KB
testcase_25 AC 78 ms
31,488 KB
testcase_26 AC 79 ms
31,616 KB
testcase_27 AC 80 ms
31,616 KB
testcase_28 AC 75 ms
31,872 KB
testcase_29 AC 75 ms
31,488 KB
testcase_30 AC 78 ms
32,000 KB
testcase_31 AC 82 ms
31,488 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
  復元対象のプロジェクトを決定しています...
  /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/

ソースコード

diff #

open System

let judgeEto inseq =
    let maxNum = int (ceil (float (Seq.length inseq) / 2.))
    inseq |> Seq.groupBy id |> Seq.map (fun (key, gseq) -> Seq.length gseq) |>
    Seq.max |> (fun nmax -> nmax <= maxNum)

let N = Console.ReadLine () |> int
seq { for _ in 1..N -> Console.ReadLine ()} |> Seq.toList |> Seq.ofList |>
judgeEto |>
(fun result -> if result then "YES" else "NO") |> printfn "%s"
0