結果
問題 | No.47 ポケットを叩くとビスケットが2倍 |
ユーザー |
![]() |
提出日時 | 2015-04-30 00:35:29 |
言語 | C++11 (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 2 ms / 5,000 ms |
コード長 | 225 bytes |
コンパイル時間 | 1,179 ms |
コンパイル使用メモリ | 156,764 KB |
実行使用メモリ | 5,376 KB |
最終ジャッジ日時 | 2024-07-05 16:51:59 |
合計ジャッジ時間 | 1,956 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 21 |
コンパイルメッセージ
main.cpp: In function ‘int main()’: main.cpp:5:10: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 5 | scanf("%d",&N); | ~~~~~^~~~~~~~~
ソースコード
#include<bits/stdc++.h> using namespace std; int main(){ int N; scanf("%d",&N); for(int i=0;i<30;i++){ if((1<<i)>=N){ printf("%d\n",i); return 0; } } return 0; }