Chapter - 9
Quiz by Srinivasan J
Feel free to use or edit a copy
includes Teacher and Student dashboards
Measure skillsfrom any curriculum
Tag the questions with any skills you have. Your dashboard will track each student's mastery of each skill.
- 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
- Q1
__________________ function is used to know the data type of a python object.
Users enter free textType an Answer15s - Q2
Iterating tuples is faster than list.
truefalseTrue or False15s - Q3
A _________ is a mutable and an unordered collection of elements without duplicates.
Tuple
List
Set
Dictionary
15s - Q4
A list is known as a _________________ data type.
Users enter free textType an Answer15s - Q5
set_A={'A', 2, 4, 3, 'D', 'E'}
set_B={'A', 'B', 'C', 'D', 'E',3}
print(set_A - set_B)
What will be the result of the above snippet ?
{ 'B', 'C',}
{2, 4, 'B', 'C',}
{2, 4}
{ 'A', 'D', 'E',3}
15s - Q6
The Description of the function count ( ) is to return the number of similar elements present in the list.
truefalseTrue or False15s - Q7
View the attached image and answer.
15s - Q8
What will be the output of the following snippet ?
Mylist=[34, 45, 48]
Mylist=append(90)
[34, 45, 48, 90]
[45, 48, 90]
[34, 45, 48]
Error
15s - Q9
The elements of a list are _____________ whereas the elements of a tuple are _____________ .
mutable, immutable
mutable, mutable
immutable, mutable
immutable, immutable
15s - Q10
______________ is a list containing another list as an element.
Users enter free textType an Answer15s - Q11
List is an ordered collection of values enclosed within ___________
none of these
square brackets
curly brackets
parenthesis
15s - Q12
Which of the following operator is used for symmetric difference set operation in python ?
caret (^) operator
| operator
& operator
minus (-) operator
15s - Q13
What will be the output of the following snippet ?
MyList=[36,12,24,48]
i=MyList.index(12)
print(i)
1
0
3
2
15s - Q14
________ function is used to delete elements of a list if its index is unknown .
del statement
clear( )
del( )
remove( )
15s - Q15
View the given image and answer.
none of these
15s