結果
| 問題 |
No.1176 少ない質問
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2020-08-21 21:34:23 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 1,000 ms |
| コード長 | 203 bytes |
| コンパイル時間 | 469 ms |
| コンパイル使用メモリ | 65,136 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-10-15 05:17:26 |
| 合計ジャッジ時間 | 1,191 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 21 |
コンパイルメッセージ
main.cpp:4:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
4 | main()
| ^~~~
ソースコード
#include<iostream>
using namespace std;
long A;
main()
{
cin>>A;
long ans=A;
for(int i=2;i<=3;i++)
{
int now=0;
long T=1;
while(T<A)now++,T*=i;
if(ans>now*i)ans=now*i;
}
cout<<ans<<endl;
}