Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import math
- x_quadro = int(input())
- grapes_per_kv = float(input())
- liters_wine = int(input())
- workers = int(input())
- grapes = x_quadro * grapes_per_kv
- wines = (0.4 * grapes) / 2.5
- if wines >= liters_wine:
- wines1 = wines - liters_wine
- kef = math.ceil((wines - liters_wine) / workers)
- print(f"Good harvest this year! Total wine: {math.floor(wines)} liters.")
- print(f"{math.ceil(wines1)} liters left -> {math.ceil(kef)} liters per person.")
- else:
- #wines = math.ceil((0.4 * grapes) / 2.5)
- wines2 = liters_wine - wines
- print(f"It will be a tough winter! More {math.floor(wines2)} liters wine needed.")
Add Comment
Please, Sign In to add comment