Exam 2: An Overview of Collections
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
A set is a built-in Python collection type.
Free
(True/False)
4.8/5
(39)
Correct Answer:
True
When a for loop is used to iterate over a collection, which statement is true?
Free
(Multiple Choice)
4.8/5
(32)
Correct Answer:
C
In Python, modules and methods are the smallest units of abstraction, classes are the next in size, and functions are the largest.
Free
(True/False)
4.7/5
(38)
Correct Answer:
False
Which real-world item best represents a hierarchical collection?
(Multiple Choice)
4.9/5
(39)
If you clone an object using the = operator (as in myList=list(yourList) ), the is operator returns True while the == operator returns False.
(True/False)
4.7/5
(33)
When using a for loop to iterate over a list, the items are visited in no particular order.
(True/False)
4.8/5
(33)
What is the value of myObject after the following code executes?
YourObject = "Hi"
MyObject = tuple(yourObject)
(Multiple Choice)
4.9/5
(33)
Which operator is used to obtain a string representation of a collection?
(Multiple Choice)
4.8/5
(40)
What is the value of c after the following code executes?
A = [ 10, 20, 30 ]
B = [ 40, 50, 60 ]
C = a + b
(Multiple Choice)
4.7/5
(42)
The map, filter, and reduce functions can only be used on list collections.
(True/False)
4.8/5
(33)
Which of the following is a special case of type conversion, where the two collections are of the same type?
(Multiple Choice)
4.8/5
(36)
What is the value of aList after the following code is executed?
AList = [ 10, 20, 30 ]
AList.pop()
(Multiple Choice)
4.8/5
(37)
A sorted collection must be in a linear structure, ordered by position.
(True/False)
4.8/5
(44)
The use of collections is a Python programming requirement, but they are not very useful for working with real-world objects.
(True/False)
4.8/5
(40)
Python includes two implementations of lists: arrays and linked lists.
(True/False)
5.0/5
(35)
Showing 1 - 20 of 50
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)