Numpy Quiz
Quiz by Varun Patkar
Feel free to use or edit a copy
includes Teacher and Student dashboards
Measure skillsfrom any curriculum
Measure skills
from any curriculum
Tag the questions with any skills you have. Your dashboard will track each student's mastery of each skill.
With a free account, teachers can
- edit the questions
- save a copy for later
- start a class game
- automatically assign follow-up activities based on students’ scores
- assign as homework
- share a link with colleagues
- print as a bubble sheet
5 questions
Show answers
- Q1Why is Numpy Faster than Lists?Lists use contiguous memoryNumpy uses fixed typesLists has no typechechingNumpy disallows Broadcasting20s
- Q2Give the output: a=np.array([1,2,3]) a.shape(,3)(3,1)(3,)(1,3)20s
- Q3Which of these types of data types do not exist?float8int8int16float1620s
- Q4d=np.array([[1,2,3,4,5,6,7],[8,9,10,11,12,13,14]]) What do you put in to extract [2,4,6]d[0,1:-1:2]d[0,0:-1:2]d[1,1:-1:2]d[0,1:-3:2]45s
- Q5Which of the following code gives output as : [[1,5,5], [5,1,5], [5,5,1]](5*np.ones((3,3)))-(4*np.identity((3,3)))(5*np.identity((3,3)))-(4*np.ones(3))(5*np.ones((3,3)))-(4*np.identity(3))(4*np.ones((3,3)))-(5*np.zeros(3))45s