結果

問題 No.47 ポケットを叩くとビスケットが2倍
ユーザー aaaaaaiu
提出日時 2019-07-29 12:12:55
言語 C++17
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 3 ms / 5,000 ms
コード長 225 bytes
コンパイル時間 2,338 ms
コンパイル使用メモリ 191,784 KB
最終ジャッジ日時 2025-01-07 09:55:40
ジャッジサーバーID
(参考情報)
judge2 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 21
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;

int main() {
    int n;
    cin>>n;
    n--;
    int ans = 0;
    while (n) {
        n >>= 1;
        ans++;
    }
    cout << ans << endl;
    return 0;
}
0