結果
問題 |
No.804 野菜が苦手
|
ユーザー |
![]() |
提出日時 | 2019-10-01 19:20:44 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
AC
|
実行時間 | 32 ms / 2,000 ms |
コード長 | 318 bytes |
コンパイル時間 | 156 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 10,752 KB |
最終ジャッジ日時 | 2024-10-03 05:45:47 |
合計ジャッジ時間 | 1,481 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 18 |
ソースコード
line = input().split(" ") vegi = int(line[0]) meat = int(line[1]) meatCons = int(line[2]) vegicons = 1 total = int(line[3]) cnt = 0 while True: vegi -= 1 meat -= meatCons total -= (vegicons + meatCons) if (vegi < 0 or meat < 0): break if (total < 0): break cnt += 1 print(cnt)