結果
| 問題 | No.1517 Party Location |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2022-12-16 19:25:58 |
| 言語 | C++11(old_compat) (gcc 12.4.0 + boost 1.90.0) |
| 結果 |
AC
|
| 実行時間 | 1 ms / 2,000 ms |
| + 337µs | |
| コード長 | 242 bytes |
| 記録 | |
| コンパイル時間 | 870 ms |
| コンパイル使用メモリ | 163,668 KB |
| 実行使用メモリ | 5,888 KB |
| 最終ジャッジ日時 | 2026-07-28 02:29:25 |
| 合計ジャッジ時間 | 2,075 ms |
|
ジャッジサーバーID (参考情報) |
judge3_1 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 13 |
ソースコード
#include <iostream>
using namespace std;
int main()
{
int d, a, b;
cin >> d >> a >> b;
int minv = INT32_MAX;
for (int i = 0; i <= d; i++)
{
minv = min(minv, i * a + (d - i) * b);
}
cout << minv << endl;
}