NumPy - Creating Arrays
What will be the output of the following code?
import numpy as np arr = np.zeros((2,3)) print(arr.shape)
import numpy as np arr = np.zeros((2,3)) print(arr.shape)
arr.shapeshape attribute returns a tuple representing the dimensions, so it will be (2, 3).15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions