Im getting error message " larger_list([2, 5], [3, 7, 10]) should have returned 10 , and it returned [3, 7, 10]"

My output is “5”

and the solution shows 5. Why am getting this?
my code below:


1 Like

@mowglie, read the instructions again.

1 Like

Well, I believe I may be lost because my code and and the solution code are giving me the same output. The soluions code is just better compiled:

Solution code:


Did you test them on any other inputs? What is the output of your code and the solution code to this:

print(larger_list([4, 10, 2, 5], [-10, 2, 5, 10, 11, 12]))


Ok, I managed to get it right, obviously when I changed the inputs everything changed because I didnt asked for last element in the other statements [-1]. Which for some reason I forgot to place. Thank you for the wake up call.