+ 1

Please why am i not getting 2/5 cases from New drivers license. Here's my code..

my_name= input() available_agents = int(input ()) other_names= input () _split=other_names.split(',') all_names = _split.append(my_name) _sorted = sorted(_split) time =( 20 *((_sorted.index(my_name))+1)) // available_agents print(time)

10th Aug 2020, 9:31 AM
Eleojo Emmanuel Adegbe
Eleojo Emmanuel Adegbe - avatar
3 odpowiedzi
10th Aug 2020, 9:39 AM
AKSHAY🇮🇳
AKSHAY🇮🇳 - avatar
+ 1
time = etc.... This section is causing the problem as it is not outputting in increments of 20 minutes. Remember it takes 1 agent 20 minutes to process 1 licence /person. If you had 3 agents and 1 customer, it will still take 20 minutes. Your code would return 7 minutes .
10th Aug 2020, 10:03 AM
Rik Wittkopp
Rik Wittkopp - avatar