結果
| 問題 |
No.804 野菜が苦手
|
| コンテスト | |
| ユーザー |
mine691
|
| 提出日時 | 2019-03-22 22:01:05 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 352 bytes |
| コンパイル時間 | 561 ms |
| コンパイル使用メモリ | 63,328 KB |
| 実行使用メモリ | 6,944 KB |
| 最終ジャッジ日時 | 2024-09-19 05:22:47 |
| 合計ジャッジ時間 | 1,285 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 17 WA * 1 |
ソースコード
#include <iostream>
using namespace std;
using ll = long long;
int main()
{
int a, b, c, d, ans = 0;
cin >> a >> b >> c >> d;
if (1 + c > d)
{
cout << 0 << endl;
}
else
{
while (a > 0 && b >= c)
{
ans++;
b -= c;
a--;
}
cout << ans << endl;
}
}
mine691