Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- chrysanthemums = int(input())
- roses = int(input())
- tulips = int(input())
- season = str(input()).lower()
- holiday = input().lower()
- bouquet = chrysanthemums + roses + tulips # брой цветя
- flowers_price = 0 # цена на букетът
- if season == 'spring' or season == 'summer':
- flowers_price += chrysanthemums * 2.00
- flowers_price += roses * 4.10
- flowers_price += tulips * 2.50
- elif season == 'autumn' or season == 'winter':
- flowers_price += chrysanthemums * 3.75
- flowers_price += roses * 4.50
- flowers_price += tulips * 4.15
- if holiday == 'y':
- flowers_price *= 1.15
- if tulips > 7 and season == 'spring':
- flowers_price *= 0.95
- if roses >= 10 and season == 'winter':
- flowers_price *= 0.90
- if bouquet > 20:
- flowers_price *= 0.80
- print('%.2f' % (flowers_price + 2))
Add Comment
Please, Sign In to add comment