- 3

My question on how to get this code correct

When you go out to eat, you always tip 20% of the bill amount. But who’s got the time to calculate the right tip amount every time? Not you that’s for sure! You’re making a program to calculate tips and save some time. Your program needs to take the bill amount as input and output the tip as a float. Sample Input 50 Sample Output 10.0

25th Feb 2022, 9:13 PM
Avz
Avz - avatar
3 Answers
+ 4
bill=int(input()) tip = bill*20/100 print(tip)
26th Feb 2022, 2:09 PM
Vaibhav
Vaibhav - avatar
+ 1
Thank you Muhammad I appreciate it 🙏
25th Feb 2022, 9:41 PM
Avz
Avz - avatar
0
bill = int(input()) tip = 20/100 print (price * bill)
25th Feb 2022, 9:18 PM
Muhammad Galhoum
Muhammad Galhoum - avatar