Examveda

What will be the output of the following Python code snippet?
x = [i**+1 for i in range(3)]; print(x);

A. [0, 1, 2]

B. [1, 2, 5]

C. error, **+ is not a valid operator

D. error, ';' is not allowed

Answer: Option A


This Question Belongs to Python Program >> Lists In Python

Join The Discussion

Related Questions on Lists in Python