@@ -85,8 +85,8 @@ Create a 3x3 matrix with values ranging from 0 to 8 (★☆☆)
|
|||||||
hint: reshape
|
hint: reshape
|
||||||
|
|
||||||
< a9
|
< a9
|
||||||
nz = np.nonzero([1,2,0,0,4,0])
|
Z = np.arange(9).reshape(3, 3)
|
||||||
print(nz)
|
print(Z)
|
||||||
|
|
||||||
< q10
|
< q10
|
||||||
Find indices of non-zero elements from [1,2,0,0,4,0] (★☆☆)
|
Find indices of non-zero elements from [1,2,0,0,4,0] (★☆☆)
|
||||||
|
|||||||
Reference in New Issue
Block a user