結果
問題 | No.920 あかあお |
ユーザー |
![]() |
提出日時 | 2019-12-08 17:08:27 |
言語 | F# (F# 4.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 587 bytes |
コンパイル時間 | 18,850 ms |
コンパイル使用メモリ | 198,188 KB |
実行使用メモリ | 34,744 KB |
最終ジャッジ日時 | 2024-12-30 20:18:06 |
合計ジャッジ時間 | 25,285 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 8 WA * 3 |
コンパイルメッセージ
復元対象のプロジェクトを決定しています... /home/judge/data/code/main.fsproj を復元しました (736 ms)。 MSBuild のバージョン 17.9.6+a4ecab324 (.NET) /home/judge/data/code/Main.fs(22,9): warning FS0025: この式のパターン マッチが不完全です たとえば、値 '[|_; _; _; _|]' はパターンに含まれないケースを示す可能性があります。 [/home/judge/data/code/main.fsproj] main -> /home/judge/data/code/bin/Release/net8.0/main.dll main -> /home/judge/data/code/bin/Release/net8.0/publish/
ソースコード
open System[<AutoOpen>]module Cin =let read f = stdin.ReadLine() |> flet reada f = stdin.ReadLine().Split() |> Array.map flet readInts() =read string|> Seq.toArray|> Array.map (fun x -> Convert.ToInt32(x.ToString()))module Util =let strRev s =s|> Seq.rev|> Seq.map string|> String.concat ""[<EntryPoint>]let main _ =let [|X;Y;Z|] = reada intlet nin = min X Ylet nax = max X Ylet rem = Z - max 0 (nax-nin)printfn "%d" (nax + rem / 2)0 // return an integer exit code