結果

問題 No.531 エヌスクミ島の平和協定
ユーザー taktak
提出日時 2018-04-09 08:04:10
言語 F#
(F# 4.0)
結果
AC  
実行時間 354 ms / 2,000 ms
コード長 622 bytes
コンパイル時間 9,714 ms
コンパイル使用メモリ 190,376 KB
実行使用メモリ 36,004 KB
最終ジャッジ日時 2023-10-19 22:37:54
合計ジャッジ時間 23,304 ms
ジャッジサーバーID
(参考情報)
judge14 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 352 ms
35,996 KB
testcase_01 AC 353 ms
35,992 KB
testcase_02 AC 351 ms
35,508 KB
testcase_03 AC 348 ms
35,508 KB
testcase_04 AC 350 ms
35,992 KB
testcase_05 AC 350 ms
35,508 KB
testcase_06 AC 351 ms
35,508 KB
testcase_07 AC 351 ms
35,992 KB
testcase_08 AC 349 ms
35,992 KB
testcase_09 AC 351 ms
35,992 KB
testcase_10 AC 350 ms
35,688 KB
testcase_11 AC 349 ms
35,688 KB
testcase_12 AC 348 ms
35,688 KB
testcase_13 AC 349 ms
35,508 KB
testcase_14 AC 347 ms
35,688 KB
testcase_15 AC 349 ms
35,992 KB
testcase_16 AC 351 ms
35,992 KB
testcase_17 AC 352 ms
35,992 KB
testcase_18 AC 351 ms
35,996 KB
testcase_19 AC 350 ms
35,508 KB
testcase_20 AC 351 ms
35,688 KB
testcase_21 AC 354 ms
35,508 KB
testcase_22 AC 352 ms
35,508 KB
testcase_23 AC 350 ms
35,508 KB
testcase_24 AC 351 ms
35,508 KB
testcase_25 AC 351 ms
35,508 KB
testcase_26 AC 350 ms
35,992 KB
testcase_27 AC 350 ms
35,996 KB
testcase_28 AC 350 ms
35,688 KB
testcase_29 AC 352 ms
36,004 KB
testcase_30 AC 349 ms
35,988 KB
testcase_31 AC 351 ms
36,004 KB
testcase_32 AC 350 ms
35,992 KB
testcase_33 AC 351 ms
35,972 KB
testcase_34 AC 351 ms
35,988 KB
testcase_35 AC 350 ms
35,992 KB
testcase_36 AC 351 ms
35,988 KB
testcase_37 AC 350 ms
35,992 KB
testcase_38 AC 350 ms
35,992 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
  復元対象のプロジェクトを決定しています...
  /home/judge/data/code/main.fsproj を復元しました (293 ms)。
MSBuild のバージョン 17.7.3+8ec440e68 (.NET)
  main -> /home/judge/data/code/bin/Release/net7.0/main.dll
  main -> /home/judge/data/code/bin/Release/net7.0/publish/

ソースコード

diff #

open System
open System.Collections.Generic

[<AutoOpen>]
module hoge = 
    let inline dump e =
    #if DEBUG
        printfn "%A" e; 
    #endif
        e
    let read() = stdin.ReadLine()
    let reads() = read().Split()
    let readToEnd() = stdin.ReadToEnd()
    let lines(s:string) = s.Split([|stdout.NewLine|], StringSplitOptions.RemoveEmptyEntries) 

let (|ODD|EVE|) n = 
    match n%2 with
    | 0 -> EVE
    | _ -> ODD

let n,m = let t = reads() |> Array.map(int) in t.[0],t.[1]

if n<=m then 1
else
    match n with 
    | ODD -> -1
    | EVE ->
        if n/2<=m then 2
        else          -1
|> printfn "%i"
0