Examveda

What will be the output of the following Python code?
a=[[]]*3
a[1].append(7)
print(a)

A. Syntax error

B. [[7], [7], [7]]

C. [[7], [], []]

D. [[],7, [], []]

Answer: Option B


This Question Belongs to Python Program >> Lists In Python

Join The Discussion

Related Questions on Lists in Python