結果
問題 |
No.143 豆
|
ユーザー |
![]() |
提出日時 | 2016-04-14 20:33:33 |
言語 | F# (F# 4.0) |
結果 |
AC
|
実行時間 | 336 ms / 1,000 ms |
コード長 | 351 bytes |
コンパイル時間 | 9,807 ms |
コンパイル使用メモリ | 187,972 KB |
実行使用メモリ | 36,068 KB |
最終ジャッジ日時 | 2024-07-23 10:28:48 |
合計ジャッジ時間 | 14,988 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 17 |
コンパイルメッセージ
復元対象のプロジェクトを決定しています... /home/judge/data/code/main.fsproj を復元しました (236 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/
ソースコード
open System let No143 () = let IN = Console.ReadLine().Split(' ') let B = (Int32.Parse IN.[0]) * (Int32.Parse IN.[1]) let last n = if B - n < 0 then printfn "-1" else printfn "%d" (B - n) Console.ReadLine().Split(' ') |> Array.map Int32.Parse |> Array.sum |> last () No143 ()