Class 12 Computer Science Chapter 1 Data Structures Using Python Quiz 1 (25 MCQs)

Quiz Instructions

Select an option to see the correct answer instantly.

1. Consider the usual algorithm for determining whether a sequence of parentheses is balanced.Suppose that you run the algorithm on a sequence that contains 2 left parentheses and 3 right parentheses (in some order).The maximum number of parentheses that appear on the stack AT ANY ONE TIME during the computation?
2. Array can be classified in how many types?
3. ..... is very useful in situation when data have to stored and then retrieved in reverse order.
4. What is the time complexity of deleting from the rear end of the dequeue implemented with a singly linked list?
5. What is the advantage of using a priority queue over a regular queue?
6. What will this code do? colors[1] = "yellow"
7. How do you access elements in a tuple?
8. What is the difference between a list and a dictionary?
9. How do you check if a variable is equal to a specific value using if-else?
10. For the 'Calculating Percent Markup' activity, what validation should the function include?
11. How do you append an element to a list in Python?
12. B-tree and AVL tree have the same worst case time complexity for insertion and deletion.
13. What is a two-dimensional array visualized as?
14. What is the time complexity to insert an element to the front of a LinkedList(head pointer given)?
15. Root has more left descendants than the right descendants or vice versa.
16. Which data structure is suitable for implementing a breadth-first search algorithm?
17. Which of the following is not an advantage of trees?
18. What is the purpose of the del statement in Python?
19. Data word is?
20. In a graph if E=(u, v) means .....
21. Pushing an element into stack already having five elements and stack size of 5, then stack becomes
22. Which of the following is the disadvantage of the array?
23. Which among the below specified condition is applicable if the Queue is non-empty?
24. What are the main differences between a list and a set in Python?
25. What is a tuple?