Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import math
- sushi_type = input()
- name_restaurant = input()
- N_portion = int(input())
- take_home = input()
- price_food = 0
- if name_restaurant == 'Sushi Zone':
- if sushi_type == 'sashimi':
- price_food = 4.99
- elif sushi_type == 'maki':
- price_food = 5.29
- elif sushi_type == 'uramaki':
- price_food = 5.99
- elif sushi_type == "temaki":
- price_food = 4.29
- total_price = price_food * N_portion
- if take_home == 'Y':
- total_price = math.ceil(total_price * 1.2)
- print(f'Total price: {math.ceil(total_price)} lv.')
- elif name_restaurant == 'Sushi Time':
- if sushi_type == 'sashimi':
- price_food = 5.49
- elif sushi_type == 'maki':
- price_food = 4.69
- elif sushi_type == 'uramaki':
- price_food = 4.49
- elif sushi_type == "temaki":
- price_food = 5.19
- total_price = price_food * N_portion
- if take_home == 'Y':
- total_price = math.ceil(total_price * 1.2)
- print(f'Total price: {math.ceil(total_price)} lv.')
- elif name_restaurant == 'Sushi Bar':
- if sushi_type == 'sashimi':
- price_food = 5.25
- elif sushi_type == 'maki':
- price_food = 5.55
- elif sushi_type == 'uramaki':
- price_food = 6.25
- elif sushi_type == "temaki":
- price_food = 4.75
- total_price = price_food * N_portion
- if take_home == 'Y':
- total_price = math.ceil(total_price * 1.2)
- print(f'Total price: {math.ceil(total_price)} lv.')
- elif name_restaurant == 'Asian Pub':
- if sushi_type == 'sashimi':
- price_food = 4.5
- elif sushi_type == 'maki':
- price_food = 4.8
- elif sushi_type == 'uramaki':
- price_food = 5.50
- elif sushi_type == "temaki":
- price_food = 5.5
- total_price = price_food * N_portion
- if take_home == 'Y':
- total_price = math.ceil(total_price * 1.2)
- print(f'Total price: {math.ceil(total_price)} lv.')
- else:
- print(f'{name_restaurant} is invalid restaurant!')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement