Guest User

Untitled

a guest
Oct 17th, 2016
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. call_length = int(input("Length of call (minutes):"))
  2. call_placed = int(input("Hour of call (24 hour format):"))
  3.  
  4. total_cost = .08 * call_length
  5.  
  6. if 18 < call_placed < 24:
  7. total_cost * .25
  8. elif call_length > 30:
  9. total_cost * .10
  10.  
  11.  
  12. if 0 < call_placed < 8:
  13. total_cost * .50
  14. elif call_length > 30:
  15. total_cost * .10
  16.  
  17.  
  18. print("Total price of call: ${:.2f}".format(total_cost))
Advertisement
Add Comment
Please, Sign In to add comment