So the problem is this:
Design a program that asks the user to enter a store’s sales for each day of the week. The amounts should be stored in an array. Use a loop to calculate the total sales for the week and display the result.
This is what I have so far,
maxValue = 7
sales = 0
index = 0
totalSales = [maxValue]
for index in range(0, maxValue - 1):
totalSales[index] = float(input("Enter today's sales: $"))
I know it's in issue with bounds, I am getting the error IndexError: list assignment index out of range after I enter my second input.
After debugging I can see that totalSale = [maxValue] is giving the list a length of one.. but I don't understand how to fix this. I appreciate the help!