結果

問題 No.47 ポケットを叩くとビスケットが2倍
ユーザー taktak
提出日時 2019-02-10 17:17:12
言語 F#
(F# 4.0)
結果
AC  
実行時間 83 ms / 5,000 ms
コード長 173 bytes
コンパイル時間 4,260 ms
コンパイル使用メモリ 154,664 KB
実行使用メモリ 24,852 KB
最終ジャッジ日時 2023-09-20 18:44:46
合計ジャッジ時間 7,224 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 80 ms
20,736 KB
testcase_01 AC 81 ms
24,828 KB
testcase_02 AC 80 ms
22,796 KB
testcase_03 AC 79 ms
20,708 KB
testcase_04 AC 80 ms
24,808 KB
testcase_05 AC 80 ms
22,796 KB
testcase_06 AC 80 ms
24,852 KB
testcase_07 AC 79 ms
22,756 KB
testcase_08 AC 80 ms
24,812 KB
testcase_09 AC 79 ms
24,812 KB
testcase_10 AC 80 ms
22,768 KB
testcase_11 AC 81 ms
22,768 KB
testcase_12 AC 79 ms
22,784 KB
testcase_13 AC 79 ms
22,656 KB
testcase_14 AC 79 ms
22,768 KB
testcase_15 AC 79 ms
22,776 KB
testcase_16 AC 80 ms
24,768 KB
testcase_17 AC 81 ms
24,760 KB
testcase_18 AC 81 ms
24,824 KB
testcase_19 AC 80 ms
22,768 KB
testcase_20 AC 79 ms
22,732 KB
testcase_21 AC 83 ms
22,888 KB
testcase_22 AC 80 ms
22,716 KB
testcase_23 AC 79 ms
24,808 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) F# Compiler version 11.0.0.0 for F# 5.0
Copyright (c) Microsoft Corporation. All Rights Reserved.

ソースコード

diff #

let biscuit n = 
  let rec f target n acc =
    if n >= target then acc
    else f target (n*2) (acc+1)
  f n 1 0

let n = stdin.ReadLine() |> int

biscuit n
|> printfn "%i"
0