Question: Write a Python program to: Read the amount of a purchase from the user Calculate the amount of GST Calculate the total with GST

 

Write a Python program to: Read the amount of a purchase from the user Calculate the amount of GST Calculate the total with GST Print out a formatted sales receipt (example below) Your program should include a main function and at least one other function. Use appropriate Python style convention. Assume that the GST is 5% and that the user provides valid input. The output should look like the following (where 10.50 is an example input, this value should not be hard coded): Enter the amount of your purchase: 10.50 Amount of purchase: $10.50 Amount of GST: $0.53 Total purchase: $11.03

Step by Step Solution

3.38 Rating (151 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

def calculategstamount gst amount 005 return gst def calculatetotalamount gst ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!