Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- type_flowers = input()
- count_flowers = int(input())
- budget = int(input())
- total_sum = 0
- if type_flowers == 'Roses':
- total_sum = 5 * count_flowers
- if count_flowers > 80:
- total_sum -= (total_sum * 0.10)
- elif type_flowers == 'Dahlias':
- total_sum = 3.80 * count_flowers
- if count_flowers > 90:
- total_sum -= (total_sum * 0.15)
- elif type_flowers == 'Tulips':
- total_sum = 2.80 * count_flowers
- if count_flowers > 80:
- total_sum -= (total_sum * 0.15)
- elif type_flowers == 'Narcissus':
- total_sum = 3 * count_flowers
- if count_flowers < 120:
- total_sum += (total_sum * 0.15)
- else:
- total_sum = 2.50 * count_flowers
- if count_flowers < 80:
- total_sum += (total_sum * 0.20)
- diff = abs(budget - total_sum)
- if budget >= total_sum:
- print(f"Hey, you have a great garden with {count_flowers} {type_flowers} and {diff:.2f} leva left.")
- else:
- print(f"Not enough money, you need {diff:.2f} leva more.")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement