Skip to content
ml-recall

#array-shapes

2 questions from NumPy

Timed test

2 questions · 2 min · score and explanations at the end

Take a test
Q 1 / 2Score 0 / 0

Question 1: Short answer

mediumAI-checkedNumPy

What is neg.shape?

a = np.array([[1, -2], [-3, 4]])
neg = a[a < 0]

A shape in parentheses, e.g. (5,) or (5, 6)