結果
問題 |
No.176 2種類の切手
|
ユーザー |
|
提出日時 | 2016-10-04 18:33:20 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 309 bytes |
コンパイル時間 | 700 ms |
コンパイル使用メモリ | 67,784 KB |
実行使用メモリ | 6,820 KB |
最終ジャッジ日時 | 2024-11-21 16:12:17 |
合計ジャッジ時間 | 5,316 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 23 WA * 4 TLE * 2 |
ソースコード
#pragma GCC optimize "O3,omit-frame-pointer,inline" #include <iostream> using namespace std; int main() { int a, b, t; cin >> a >> b >> t; int y = t + b; for (int i = 0; i <= t; i += b) { int x = i + (t - i + a-1)/a*a; if (x < y) y = x; } cout << y << endl; return 0; }