-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathHour2.py
More file actions
24 lines (19 loc) · 668 Bytes
/
Hour2.py
File metadata and controls
24 lines (19 loc) · 668 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
"""
Sams Teach Yourself Python in 24 Hours
by Katie Cunningham
Hour 2: Putting Numbers to Work in Python
Exercise:
1.
a) Write a single line of code that will satisfy this situation:
You're ordering some supplies from a store, and you need to
figure out what the total price is.
Supplies cost: $10.00
Discount: 30%
Sales Tax: 5%
Shipping: $7.50
"""
####Hour 2: Putting Numbers to Work in Python
##Total = (10 - (10 * .3)) + (10 * .05) + (7.50)
#### (Discount Price) + (Sales Tax) + (Shipping)
##print ("Total Price: $" + str(Total))
print("Total Price: $" + str((10 - (10 * .3)) + (10 * .05) + (7.50)))