Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Car salesman program where the user enters the base price of a car.
- # A bunch of extra fees such as tax, license, dealer prep, and destination charge will be added.
- # Tax and licence will be a percent of the base price.
- # The other fees will have set values.
- #The actual price of the car once all the extras are applied will be displayed.
- base = int(input("What is the base price of the car? £"))
- tax = base * 0.2
- licence = base * 0.15
- dealerprep = int(100)
- destinationcharge = int(70)
- print ("\n\nextra fees".upper())
- print ("\nvariable fees".title())
- print ("tax fees: £" , tax)
- print ("Licence fees £" , licence)
- print ("\nfixed fees".title())
- print ("Dealer prep: £{}".format(dealerprep))
- print ("Destination charge: £" , + str(destinationcharge)
- total = tax + licence + dealerprep + destinationcharge
- print ("\n\ntotal cost: £".upper() , total)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement