Exam 9: Dictionaries and Sets
Exam 1: Introduction to Computers and Programming39 Questions
Exam 2: Input, Processing, and Output40 Questions
Exam 3: Decision Structures and Boolean Logic40 Questions
Exam 4: Repetition Structures41 Questions
Exam 5: Functions66 Questions
Exam 6: Files and Exceptions40 Questions
Exam 7: Lists and Tuples40 Questions
Exam 8: More About Strings37 Questions
Exam 9: Dictionaries and Sets39 Questions
Exam 10: Classes and Object-Oriented Programming38 Questions
Exam 11: Inheritance36 Questions
Exam 12: Recursion35 Questions
Exam 13: Gui Programming42 Questions
Select questions type
The elements in a dictionary are stored in ascending order,by the keys of the key-value pairs.
(True/False)
4.7/5
(76)
The set remove and discard methods behave differently only when a specified item is not found in the set.
(True/False)
4.8/5
(64)
To add a single item to a set,you can use the set __________ method.
(Short Answer)
4.8/5
(62)
Which method can be used to add a group of elements to a set?
(Multiple Choice)
4.9/5
(80)
What will be displayed after the following code executes? (Note: the order of the display of entries in a dictionary are not in a specific order.)

(Multiple Choice)
5.0/5
(86)
What is the process used to convert an object to a stream of bytes that can be saved in a file?
(Multiple Choice)
4.8/5
(75)
What will be displayed after the following code executes? (Note: the order of the display of entries in a dictionary are not in a specific order.)

(Multiple Choice)
4.9/5
(68)
The elements in a dictionary are not stored in a specific order.
Therefore,a dictionary is not a(n)___________.
(Short Answer)
4.7/5
(78)
In a dictionary,you use a(n)__________ to locate a specific value.
(Multiple Choice)
4.8/5
(67)
What will be displayed after the following code executes? (Note: the order of the display of entries in a dictionary are not in a specific order.)

(Multiple Choice)
4.8/5
(75)
Which method would you use to get all the elements in a dictionary returned as a list of tuples?
(Multiple Choice)
4.8/5
(76)
To determine whether or not a key is included in a dictionary,or if an element is included in a set,you can use the ___________ operator.
(Short Answer)
4.8/5
(81)
The __________ method returns a value associated with a specific key and,if found,removes that key-value pair from the dictionary.
(Short Answer)
4.9/5
(78)
If you try to retrieve a value from a dictionary using a nonexistent key,a KeyError exception is raised.
(True/False)
4.9/5
(70)
The issubset()method can be used to determine whether set1 is a subset of set2.
(True/False)
4.9/5
(79)
Each element in a(n)__________ has two parts: a key and a value.
(Short Answer)
4.8/5
(83)
Showing 21 - 39 of 39
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)