Valerie Meunier

Valerie Meunier

  • 825
  • 693
  • 73.5k

why only first character in array?

Apr 9 2023 1:39 PM


this code puts only the first character in the third element of the array. How come and how to solve this?

Thanks. V.

import numpy as np
arr = np.array(["","",""])
print(arr[2]) # show only 'a'

Answers (4)