import math
# The volume of a sphere with radius r is 4/3 times pi times the cube of the
# radius. What is the volume of a sphere with radius 5?
radius = 5
volume = 4 / 3 * math.pi * radius**3
print("volume = ", volume)
# Suppose the cover price of a book is $24.95, but bookstores get a 40%
# discount. Shipping costs $3 for the first copy and 75 cents for each
# additional copy. What is the total wholesale cost for 60 copies?
price = 24.95
discount_price = price * 0.6 # 40% discount means they are paying 60%
copies = 60
wholesale_cost = 3 + (0.75 * (copies - 1)) + copies * discount_price
print("total cost = ", wholesale_cost)
# If I leave my house at 6:52 am and run 1 mile at an easy pace (8:15 per
# mile), then 3 miles at tempo (7:12 per mile) and 1 mile at easy pace again,
# what time do I get home for breakfast?
run_time_in_seconds = 2 * (8 * 60 + 15) + 3 * (7 * 60 + 12)
run_time_in_minutes = int(run_time_in_seconds / 60)
minutes_after_midnight = 6 * 60 + 52 + run_time_in_minutes
clock_hours = int(minutes_after_midnight / 60)
clock_minutes = minutes_after_midnight - clock_hours * 60
return_time = str(clock_hours) + ":" + str(clock_minutes)
print("return time = ", return_time)