結果
| 問題 |
No.1010 折って重ねて
|
| コンテスト | |
| ユーザー |
otamay6
|
| 提出日時 | 2019-11-02 02:23:58 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 509 bytes |
| コンパイル時間 | 1,574 ms |
| コンパイル使用メモリ | 165,388 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-11-16 00:17:56 |
| 合計ジャッジ時間 | 2,673 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 3 |
| other | AC * 1 WA * 42 |
ソースコード
#include<bits/stdc++.h>
#include<unistd.h>
#define REP(i,n) for(int i=0,i##_len=(n);i<i##_len;++i)
#define rep(i,a,b) for(int i=int(a);i<int(b);++i)
#define All(x) (x).begin(),(x).end()
using namespace std;
typedef long long ll;
int lie(ll x,ll y,ll h){
if(x>y) swap(x,y);
int res=0;
while(x>h){
x/=2;
h*=2;
res++;
}
while(y>h){
y/=2;
h*=2;
res++;
}
return res;
}
int main(){
ll x,y,h;cin>>x>>y>>h;
cout<<lie(x,y,h)<<endl;
}
otamay6