What does np.arange(0, 10, 2) produce in Python?
-
A
[0 2 4 6 8]
Correct answer
-
B
[0 2 4 6 8 10]
-
C
[2 4 6 8 10]
-
D
[0 1 2 3 4]
Correct answer
A. [0 2 4 6 8]
6 views
Explanation
arange excludes the stop value.
Doubts & discussion
Not sure why the answer is A? Ask here and get an explanation.
Ask a doubt about this MCQ