What is the output of the following code ?
def foo(arg, value): print(arg(value)) foo(max, [4, 5, 6]) foo(min, [4, 5, 6])
Function names are also be passed to another function.So arg will be assigned to max and min for calls foo(max, [4, 5, 6]) and foo(min, [4, 5, 6])
foo(max, [4, 5, 6])
foo(min, [4, 5, 6])
Comment here: