最后活跃于 1715843407

修订 0ac9f9b2a2abdcf77bf1c942359bdb7159f37630

q24.py 原始文件
1# Using NumPy, write a program to create two 1-dimensional array and perform the operation of iteration, sorting the
2# contents of array and concatenating the contents of the array.
3
4import numpy as np
5
6arr = np.array([9, 4, 6, 2, 7])
7
8for e in np.nditer(arr):
9 print(e)
10
11print(np.sort(arr))
12print(np.concatenate((arr, np.array([38, 77, 29, 84, 75]))))
13