Question: i need an example to explain this code ( i need the example to be explained like this photo not just raw data ) This
i need an example to explain this code i need the example to be explained like this photo not just raw data
This is the code below:
def inputdeadlines:
deadlines
while True:
userinput inputEnter course name, week of submission the project, and submission day or 'exit' to stop: strip
if userinput.lower "exit":
break
else:
course, week, day userinput.split
deadlines.appendcoursecapitalize intweek day
return deadlines
def arrangedeadlinesnaivedeadlines:
return sorteddeadlines keylambda x: x:
if namemain:
deadlines inputdeadlines
arrangeddeadlines arrangedeadlinesnaivedeadlines
printArranged Deadlines Naive Approach:
for deadline in arrangeddeadlines:
printdeadline deadline deadline
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
