結果
問題 | No.555 世界史のレポート |
ユーザー |
|
提出日時 | 2025-05-15 22:19:18 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 294 bytes |
コンパイル時間 | 1,815 ms |
コンパイル使用メモリ | 193,596 KB |
実行使用メモリ | 7,844 KB |
最終ジャッジ日時 | 2025-05-15 22:19:22 |
合計ジャッジ時間 | 2,899 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 4 WA * 16 |
ソースコード
#include <bits/stdc++.h> using namespace std; #define int long long int c, v, n; signed main() { cin >> n >> c >> v; int res = 1e18; for (int i = 1, t = 2; i <= 40; i ++ , t *= 2) res = min(res, ((n - t) / (t / 2) + bool((n - t) % (t / 2))) * v + (c + v) * i); cout << res; return 0; }