How do I fix this error? I get an int error for this line of…
Question Answered step-by-step How do I fix this error? I get an int error for this line of… How do I fix this error? I get an int error for this line of coding.. what is wrong with it??hoursTotal= hoursTotal + int(hoursWorked) # SuperMarket.py – This program creates a report that lists weekly hours worked # by employees of a supermarket. The report lists total hours for # each day of one week. # Input: Interactive# Output: Report. # Declare variables.HEAD1 = “WEEKLY HOURS WORKED”DAY_FOOTER = “Day Total “SENTINEL = “done” # Named constant for sentinel valuehoursWorked = 0 # Current record hourshoursTotal = 0 # Hours total for a dayprevDay = “” # Previous day of weeknotDone = True # loop control print (“nn”) print(“t”+ HEAD1) print(“nn”)dayOfWeek=input(“Enter day of week or done to quit: “)if dayOfWeek == SENTINEL: NotDone = Falseelse: hoursWorked = int(input(“Enter hours worked: “)) prevDay = dayOfWeekwhile notDone == True: dayOfWeek=input(“Enter day of week or done to quit: “) hoursTotal= hoursTotal + int(hoursWorked) if prevDay!=dayOfWeek: print(“t” + DAY_FOOTER+str(hoursTotal)) if dayOfWeek==”done”: break else: prevDay = dayOfWeek hoursTotal=0 hoursTotal = input(“Enter hours worked:”) Computer Science Engineering & Technology Python Programming CIT 1113 Share QuestionEmailCopy link Comments (0)


