
Dictionaries
Quiz
•
Computers
•
11th Grade
•
Practice Problem
•
Easy
Reshma Surendran
Used 7+ times
FREE Resource
Enhance your content in a minute
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Dictionaries are set of elements.
Ordered
Unordered
Sorted
Random
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Dictionaries are _____ data types of Python.
Dictionaries are _____ data types of Python.
Mutable
Simple
Immutable
All of these
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following will raise an error if the given key is not found in the dictionary ?
del statement
pop()
getitem()
all of these
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is correct with respect to above Python code?
Which of the following is correct with respect to above Python code?
d = {"a":3,"b":7}
(a) a dictionary d is created.
(b) a and b are the keys of dictionary d.
(c) 3 and 7 are the values of dictionary d.
(d) All of these.
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What would the following code print?
d = {'spring': 'autum', "autumn": "fall", "fall":"spring"}
print (d["autumn"])
(a) autumn
(b) fall
(c) spring
(d) Error
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is printed by the following statements?
D1 = {"cat":17, "dog":6, "elephant":23, "bear":20}
print ("dog" in D1)
(a) True
(b) False
(c) Error
(d) None
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following will delete key_value pair for key = "tiger" in dictionary?
di = {"loin" : "wild", "tiger" : "wild", "cat": "domestic" : "dog" : "domestic"}
Which of the following will delete key_value pair for key = "tiger" in dictionary?
di = {"loin" : "wild", "tiger" : "wild", "cat": "domestic" : "dog" : "domestic"}
(a) del di["tiger"]
(b) di[“tiger”].delete()
(c) delete(di.["tiger"])
(d) del(di.["tiger])
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
15 questions
J808 LO1 and LO2 planning project keywords / terms
Quiz
•
9th - 11th Grade
10 questions
ôn tập học kỳ 1-lớp 5
Quiz
•
2nd Grade - University
13 questions
Word Session Quiz
Quiz
•
7th Grade - University
10 questions
Computer Education Grade 3 Volume 4 Quiz
Quiz
•
3rd Grade - University
10 questions
Python Basics
Quiz
•
11th Grade
15 questions
BTEC L2 Online World Week 1-7
Quiz
•
11th - 12th Grade
15 questions
PH 1 INFORMATIKA XI
Quiz
•
11th Grade
14 questions
Konsep K3 Fiber Optik
Quiz
•
11th Grade
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
54 questions
Analyzing Line Graphs & Tables
Quiz
•
4th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
