Find the output of the following program:
def REVERSE(a):
a.reverse()
return(a)
def YKNJS(a):
b = []
b.extend(REVERSE(a))
print(b)
a = [1, 3.1, 5.31, 7.531]
YKNJS(a)
[1, 3.1, 5.31, 7.531]
[7.531, 5.31, 3.1, 1]
IndexError
AttributeError: ‘NoneType’ object has no attribute ‘REVERSE’
This question is part of this quiz :
Python List Quiz