結果
問題 |
No.1010 折って重ねて
|
ユーザー |
|
提出日時 | 2020-04-03 12:21:04 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 629 bytes |
コンパイル時間 | 679 ms |
コンパイル使用メモリ | 90,828 KB |
実行使用メモリ | 6,948 KB |
最終ジャッジ日時 | 2024-06-28 17:45:24 |
合計ジャッジ時間 | 1,710 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 WA * 1 |
other | AC * 22 WA * 21 |
ソースコード
#include<iostream> #include<vector> #include<algorithm> #include<queue> #include<cmath> #include<iomanip> #include<map> #include<cstring> using namespace std; #define rep(i, n) for (int i = 0; i < (int)(n); i++) #define vi vector<int> #define vivi vector<vi> const int INF = int(1e9); typedef long long int ll; /* -- template -- */ int main(){ double x, y, h; cin >> x >> y >> h; h /= 1000; int count = 0; while(x > h || y > h){ if(x > y && y > h){ y /= 2; h *= 2; }else{ x /= 2; h *= 2; } ++count; } cout << count; }