In [48]:
moneyMade=0.01
total=0.01
#formats day 1
print("On day 1, I made ${:.2f} for a total of ${}." .format(moneyMade, moneyMade))
#day range
for days in range(2,32):


    #doubles the money
    moneyMade*=2
    total += moneyMade
    #formats the amount of money and days into a sentence
    print("On day {}, I made ${:,.2f} for a total of ${:,.2f}." .format(days, moneyMade, total))
On day 1, I made $0.01 for a total of $0.01.
On day 2, I made $0.02 for a total of $0.03.
On day 3, I made $0.04 for a total of $0.07.
On day 4, I made $0.08 for a total of $0.15.
On day 5, I made $0.16 for a total of $0.31.
On day 6, I made $0.32 for a total of $0.63.
On day 7, I made $0.64 for a total of $1.27.
On day 8, I made $1.28 for a total of $2.55.
On day 9, I made $2.56 for a total of $5.11.
On day 10, I made $5.12 for a total of $10.23.
On day 11, I made $10.24 for a total of $20.47.
On day 12, I made $20.48 for a total of $40.95.
On day 13, I made $40.96 for a total of $81.91.
On day 14, I made $81.92 for a total of $163.83.
On day 15, I made $163.84 for a total of $327.67.
On day 16, I made $327.68 for a total of $655.35.
On day 17, I made $655.36 for a total of $1,310.71.
On day 18, I made $1,310.72 for a total of $2,621.43.
On day 19, I made $2,621.44 for a total of $5,242.87.
On day 20, I made $5,242.88 for a total of $10,485.75.
On day 21, I made $10,485.76 for a total of $20,971.51.
On day 22, I made $20,971.52 for a total of $41,943.03.
On day 23, I made $41,943.04 for a total of $83,886.07.
On day 24, I made $83,886.08 for a total of $167,772.15.
On day 25, I made $167,772.16 for a total of $335,544.31.
On day 26, I made $335,544.32 for a total of $671,088.63.
On day 27, I made $671,088.64 for a total of $1,342,177.27.
On day 28, I made $1,342,177.28 for a total of $2,684,354.55.
On day 29, I made $2,684,354.56 for a total of $5,368,709.11.
On day 30, I made $5,368,709.12 for a total of $10,737,418.23.
On day 31, I made $10,737,418.24 for a total of $21,474,836.47.