What is the result of np.array([1, 2, 3]) * 2 in Python?
Correct answer
B. array([2, 4, 6])
6 views
B. array([2, 4, 6])
6 views
NumPy multiplies element-wise, unlike a list which repeats.
Asked in: Python Interview Data Libraries
https://docs.python.org/3/library/index.htmlNot sure why the answer is B? Ask here and get an explanation.