結果
| 問題 | No.804 野菜が苦手 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2019-03-23 08:55:43 |
| 言語 | C++17 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 360 bytes |
| 記録 | |
| コンパイル時間 | 1,632 ms |
| コンパイル使用メモリ | 191,684 KB |
| 最終ジャッジ日時 | 2025-01-07 00:08:39 |
|
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 16 WA * 2 |
ソースコード
#define _USE_MATH_DEFINES
#include <bits/stdc++.h>
using namespace std;
signed main() {
ios::sync_with_stdio(false); cin.tie(0);
int a, b, c, d;
cin >> a >> b >> c >> d;
int ans = 0;
for (int i = 0; i < 1000; i++) {
b -= c;
d -= c;
if (b < 0 || d < 0) break;
ans++, a--;
if (a == 0) break;
}
cout << ans << endl;
return 0;
}