Examveda

What will be the output of the following Python code?
def addItem(listParam):
    listParam += [1]
 
mylist = [1, 2, 3, 4]
addItem(mylist)
print(len(mylist))

A. 1

B. 4

C. 5

D. 8

Answer: Option C


This Question Belongs to Python Program >> Lists In Python

Join The Discussion

Related Questions on Lists in Python