

MCQOPTIONS
Saved Bookmarks
1. |
What is the output of the code shown? def f(x): for i in range(5): yield i g=f(8) print(list(g)) |
A. | [0, 1, 2, 3, 4] |
B. | [1, 2, 3, 4, 5, 6, 7, 8] |
C. | [1, 2, 3, 4, 5] |
D. | [0, 1, 2, 3, 4, 5, 6, 7] |
Answer» B. [1, 2, 3, 4, 5, 6, 7, 8] | |