結果

問題 No.820 Power of Two
ユーザー fusilbayonetfusilbayonet
提出日時 2019-05-27 11:35:24
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
WA  
実行時間 -
コード長 254 bytes
コンパイル時間 405 ms
コンパイル使用メモリ 37,764 KB
実行使用メモリ 8,696 KB
最終ジャッジ日時 2023-10-17 18:12:02
合計ジャッジ時間 3,965 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 2 ms
4,348 KB
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 TLE -
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <cstdio>
#include <cmath>
int main()
{
    int N, K;
    scanf("%d%d", &N, &K);
    
    N = pow(2,N); K = pow(2,K);
    for(int i=1; ; i++) {
       K *= i;
       if(K >= N) {
           printf("%d", i-1);
           return 0;
       }
    }
}
0