結果
| 問題 | No.780 オフ会 |
| コンテスト | |
| ユーザー |
tak
|
| 提出日時 | 2019-02-02 06:28:14 |
| 言語 | F# (F# 10.0) |
| 結果 |
AC
|
| 実行時間 | 227 ms / 2,000 ms |
| コード長 | 452 bytes |
| 記録 | |
| コンパイル時間 | 9,994 ms |
| コンパイル使用メモリ | 202,340 KB |
| 実行使用メモリ | 37,024 KB |
| 最終ジャッジ日時 | 2026-05-19 11:00:05 |
| 合計ジャッジ時間 | 16,479 ms |
|
ジャッジサーバーID (参考情報) |
judge1_1 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 23 |
コンパイルメッセージ
復元対象のプロジェクトを決定しています... /home/judge/data/code/main.fsproj を復元しました (299 ミリ秒)。 main -> /home/judge/data/code/bin/Release/net10.0/main.dll main -> /home/judge/data/code/bin/Release/net10.0/publish/
ソースコード
open System
type Boy = int
type Girl = int
type Student = { Boy: Boy; Girl: Girl }
let (|Pair|Alone|) x =
if x.Boy <= x.Girl then Pair
else Alone
let solve x =
let yasuo = x |> function | Pair -> "YES" | Alone -> "NO"
let left = abs <| x.Boy - x.Girl
(yasuo, left)
let A, B = let t = stdin.ReadLine().Split() |> Array.map int in t.[0], t.[1]
solve { Boy = A + 1; Girl = B }
|> fun res -> printfn "%s\n%i" (fst res) (snd res)
tak