NumPy - Creating Arrays
Which of the following is the correct syntax to create a 3x5 identity matrix with 1s on the main diagonal using
np.eye()?np.eye()?np.eye(3, 5) creates a 3x5 matrix.np.eye(3, 5) correctly uses np.eye(3, 5) to create a 3x5 matrix with 1s on the main diagonal.15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions