結果
| 問題 | No.1010 折って重ねて |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2020-04-20 00:23:23 |
| 言語 | C++14 (gcc 15.3.0 + boost 1.92.0 + ACL) |
| 結果 |
WA
不安定
|
| 実行時間 | - |
| コード長 | 542 bytes |
| 記録 | |
| コンパイル時間 | 320 ms |
| コンパイル使用メモリ | 76,160 KB |
| 実行使用メモリ | 6,528 KB |
| 最終ジャッジ日時 | 2026-09-11 00:51:19 |
| 合計ジャッジ時間 | 2,397 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 40 WA * 3 |
ソースコード
#include <iostream>
#include <string>
#include <vector>
#include <numeric>
using namespace std;
using ull = unsigned long long;
void ori(ull& w, ull& h)
{
w /= 2;
h *= 2;
}
int main()
{
ull x, y, h;
cin >> x;
cin >> y;
x *= 1000;
y *= 1000;
cin >> h;
int ope = 0;
while (true)
{
if (x < y)
{
if (x > h)
ori(x, h);
else if (y > h)
ori(y, h);
else
break;
}
else
{
if (y > h)
ori(y, h);
else if (x > h)
ori(x, h);
else
break;
}
++ope;
}
cout << ope << endl;
return 0;
}