結果
問題 |
No.47 ポケットを叩くとビスケットが2倍
|
ユーザー |
|
提出日時 | 2018-03-28 22:44:04 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 161 bytes |
コンパイル時間 | 291 ms |
コンパイル使用メモリ | 30,848 KB |
実行使用メモリ | 6,948 KB |
最終ジャッジ日時 | 2024-06-25 13:21:56 |
合計ジャッジ時間 | 1,213 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 20 WA * 1 |
コンパイルメッセージ
main.cpp: In function ‘int main()’: main.cpp:5:8: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 5 | scanf("%d",&N); | ~~~~~^~~~~~~~~
ソースコード
#include <stdio.h> #include <math.h> int main() { int N; scanf("%d",&N); int n = log(N)/log(2); printf("%d\n",log(N)/(n*log(2))==1?n:n+1); return 0; }