You are viewing a single comment's thread. Return to all comments →
look at my code its not correct for 3rd test case of day 2
import sys
if name == 'main': meal_cost = float(input()) tip_percent = int(input()) tax_percent = int(input()) tip_amount = meal_cost * tip_percent / 100 tax_amount = meal_cost * tax_percent / 100 total = meal_cost + tip_amount + tax_amount print( int(total))
Seems like cookies are disabled on this browser, please enable them to open this website
Day 2: Operators
You are viewing a single comment's thread. Return to all comments →
look at my code its not correct for 3rd test case of day 2
!/bin/python3
import sys
if name == 'main': meal_cost = float(input()) tip_percent = int(input()) tax_percent = int(input()) tip_amount = meal_cost * tip_percent / 100 tax_amount = meal_cost * tax_percent / 100 total = meal_cost + tip_amount + tax_amount print( int(total))