How to initialize numpy array in Python

1 Answer

0 votes
import numpy as np 

arr = np.array([1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 31])

print(arr)



'''
run:

[ 1  3  5  7  9 11 13 15 17 19 21 23 25 31]
 
 '''

 



answered Nov 23, 2020 by avibootz
...