Exam 11: Sets and Dictionaries
Exam 1: Basic Python Programming51 Questions
Exam 2: An Overview of Collections50 Questions
Exam 3: Searching, Sorting, and Complexity Analysis50 Questions
Exam 4: Arrays and Linked Structures50 Questions
Exam 5: Interfaces, Implementations, and Polymorphism50 Questions
Exam 6: Inheritance and Abstract Classes50 Questions
Exam 7: Stacks50 Questions
Exam 8: Queues50 Questions
Exam 9: Lists50 Questions
Exam 10: Trees50 Questions
Exam 11: Sets and Dictionaries50 Questions
Exam 12: Graphs50 Questions
Select questions type
What happens when two keys map to the same index after a hashing function has been applied?
(Multiple Choice)
4.8/5
(36)
The dictionary constructor has two optional collection arguments: a collection of keys and a collection of corresponding values.
(True/False)
4.8/5
(37)
The simplest implementations of sets are subclasses of which other class?
(Multiple Choice)
4.7/5
(34)
Much like a list, a set contains items that are in a particular order.
(True/False)
4.9/5
(46)
Referring to the keysToIndexes function, what is the result of the following statement? keysToIndexes([ 39, 18, 4, 51, 6, 28 ], 9)
(Multiple Choice)
4.8/5
(36)
If S1 and s2 are sets, the expression s1.issubset(s2) returns True if s2 is a subset of s1 .
(True/False)
4.8/5
(34)
The data in sets and dictionaries are ordered by position by default.
(True/False)
4.7/5
(34)
What strategy for implementing sets attempts to approximate random access into an array for insertions, removals, and searches?
(Multiple Choice)
4.8/5
(31)
What is the value of set S after the following operations?
S = set([ 3, 9, 6 ])
S.add(6)
S.add(4)
S.remove(6)
(Multiple Choice)
4.7/5
(35)
Showing 41 - 50 of 50
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)