結果

問題 No.682 Average
ユーザー gunmakengunmaken
提出日時 2018-06-03 14:23:40
言語 F#
(F# 4.0)
結果
AC  
実行時間 82 ms / 2,000 ms
コード長 204 bytes
コンパイル時間 3,182 ms
コンパイル使用メモリ 155,104 KB
実行使用メモリ 24,904 KB
最終ジャッジ日時 2023-09-12 21:51:54
合計ジャッジ時間 5,097 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 82 ms
24,804 KB
testcase_01 AC 82 ms
24,904 KB
testcase_02 AC 81 ms
24,812 KB
testcase_03 AC 80 ms
22,748 KB
testcase_04 AC 82 ms
24,644 KB
testcase_05 AC 81 ms
24,852 KB
testcase_06 AC 82 ms
22,784 KB
testcase_07 AC 81 ms
20,820 KB
testcase_08 AC 82 ms
22,788 KB
testcase_09 AC 82 ms
20,592 KB
testcase_10 AC 81 ms
24,844 KB
testcase_11 AC 81 ms
22,748 KB
testcase_12 AC 82 ms
24,672 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) F# Compiler version 11.0.0.0 for F# 5.0
Copyright (c) Microsoft Corporation. All Rights Reserved.

ソースコード

diff #

let a, b = stdin.ReadLine().Split() |> (fun x -> int x.[0], int x.[1])
let rec hoge x =
    if x > b then 0
    elif (a + b + x) % 3 = 0 then 1 + (hoge (x + 1))
    else hoge (x + 1)
printfn "%d" (hoge a)
0