In NumPy, what is the result of the operation np.array([1, 2, 3]) + 5?

2026

In NumPy, what is the result of the operation
np.array([1, 2, 3]) + 5?

Answer: B. [6, 7, 8]

  1. A.

    An error

  2. B.

    [6, 7, 8]

  3. C.

    [1, 2, 3, 5]

  4. D.

    [5, 10, 15]

Attempted by 289 students.

Show answer & explanation

Correct answer: B

Explore the full course: Bpsc

Loading lesson…