This quiz works best with JavaScript enabled. Home > Class 12 > Class 12 Computer Science Chapter 1 Data Structures Using Python – Quiz 11 🏠 Homepage 📘 Download PDF Books 📕 Premium PDF Books Class 12 Computer Science Chapter 1 Data Structures Using Python Quiz 11 (25 MCQs) Quiz Instructions Select an option to see the correct answer instantly. 1. How do you modify an element at a specific index in a list? A) By removing the element at the specific index and adding a new element with the desired value. B) By using the 'replace' function to replace the element at the specific index with a new value. C) By accessing the element using its index and assigning a new value to it. D) By using the 'update' function to update the element at the specific index with a new value. Show Answer Correct Answer: C) By accessing the element using its index and assigning a new value to it. 2. Which data structure follows FIFO System? A) Stack. B) Queue. C) Array. D) All of these. Show Answer Correct Answer: B) Queue. 3. Which of the following operations is performed more efficiently by doubly linked list than by linear linked list? (ISRO CS 2001) A) Deleting a node whose location is given. B) Searching an unsorted list for a given item. C) Inserting a node after the node with a given location. D) Traversing the list to process each node. Show Answer Correct Answer: A) Deleting a node whose location is given. 4. Which of the following data structures allow insertion and deletion from both ends? A) Stack. B) Double Ended Queue(Deque). C) Queue. D) Strings. Show Answer Correct Answer: B) Double Ended Queue(Deque). 5. This structure uses a pointer to link nodes. A) Variable. B) Link List. C) Pointer. D) Trees. Show Answer Correct Answer: B) Link List. 6. X = 5 while x > 0:print("Counting down!") A) True. B) False. C) All the above. D) None of the above. Show Answer Correct Answer: A) True. 7. What is a nested list and how can you access its elements? A) A nested list is a flat structure; elements can be accessed in any order. B) A nested list is a type of dictionary; access elements using keys. C) A nested list is a single list with no sublists; access elements using a single index. D) A nested list is a list containing other lists; access elements using multiple indices. Show Answer Correct Answer: D) A nested list is a list containing other lists; access elements using multiple indices. 8. State true of false.i) A node is a parent if it has successor nodes.ii) A node is child node if out degree is one. A) True, True. B) False, True. C) True, False. D) False, False. Show Answer Correct Answer: C) True, False. 9. Array or linear list comes under the category of ..... A) Compound Data Structure. B) Simple Data Structure. C) Random Data Structure. D) None of these. Show Answer Correct Answer: B) Simple Data Structure. 10. What will be the output of the following code snippet for 1$\rightarrow$2$\rightarrow$3$\rightarrow$4$\rightarrow$5? void solve (ListNode* head) \{ while(head != NULL) \{ cout << head $\rightarrow$ data << '' "; head = head $\rightarrow$ next; \}\} A) 1 2 3 4 5. B) 1 3 5 2 4. C) 2 4 1 3 5. D) 5 4 3 2 1. Show Answer Correct Answer: A) 1 2 3 4 5. 11. Quick sort follows which type of algorithm A) Greed. B) Top down. C) Divide and Conquer. D) Branch and bound. Show Answer Correct Answer: C) Divide and Conquer. 12. Circular Queue is also known as ..... A) Ring Buffer. B) Square Buffer. C) Rectangle Buffer. D) Curve Buffer. Show Answer Correct Answer: A) Ring Buffer. 13. This stores its elements in a special type of tree where elements are sorted either natural or custom during iteration. A) LinkedHashSet. B) TreeSet. C) HashSet. D) Set. Show Answer Correct Answer: B) TreeSet. 14. It is a linear data structure that stores a collection of elements. Operates on first in first out (FIFO) algorithm. A) Stack. B) Data structure. C) Queue. D) Array. Show Answer Correct Answer: C) Queue. 15. In ..... type of linked lists we can traverse in both the directions. A) Singly linked list. B) Circular linked list. C) One dimensional linked list. D) Doubly linked list. Show Answer Correct Answer: D) Doubly linked list. 16. An exam was attended by 80 students. Min marks-0, Max Mark-50. I need to store the frequency of marks >30. What will be the size of the array needed for it? A) 80. B) 20. C) 30. D) 50. Show Answer Correct Answer: B) 20. 17. How do you initialize an array in C? A) Int arr[3] = (1, 2, 3);. B) Int arr(3) = \{1, 2, 3\};. C) Int arr[3] = \{1, 2, 3\};. D) Int arr(3) = (1, 2, 3);. Show Answer Correct Answer: C) Int arr[3] = \{1, 2, 3\};. 18. Consider the following operation performed on a stack of size 5.Push(1);Pop();Push(2);Push(3);Pop();Push(4);Pop();Pop();Push(5);After the completion of all operation, the number of elements present in stack are A) 1. B) 2. C) 3. D) 4. Show Answer Correct Answer: A) 1. 19. Suppose each set is represented as a linked list with elements in arbitrary order. Which of the operations among union, intersection, membership, cardinality will be the slowest? (GATE CS 2004) A) Union. B) Membership. C) Cardinality. D) Union, intersection. Show Answer Correct Answer: D) Union, intersection. 20. Explain the difference between a list and a tuple in Python. A) A list is immutable and defined with [], while a tuple is mutable and defined with (). B) Both lists and tuples are mutable and defined with []. C) A list can contain only integers, while a tuple can contain any data type. D) A list is mutable and defined with [], while a tuple is immutable and defined with (). Show Answer Correct Answer: D) A list is mutable and defined with [], while a tuple is immutable and defined with (). 21. A linked list have A) Address. B) Value. C) Both Address and value. D) None. Show Answer Correct Answer: C) Both Address and value. 22. Match the following.a) Completeness i) How long does it take to find a solutionb) Time Complexity ii) How much memory need to perform the search.c) Space Complexity iii) Is the strategy guaranteed to find the solution when there in one. A) A-iii, b-ii, c-i. B) A-i, b-ii, c-iii. C) A-iii, b-i, c-ii. D) A-i, b-iii, c-ii. Show Answer Correct Answer: C) A-iii, b-i, c-ii. 23. Compound Data structure can be ..... & ..... A) Simple and Nested. B) Linear and Non Linear. C) Sequential and random. D) None of the above. Show Answer Correct Answer: B) Linear and Non Linear. 24. The elements of static list are stored in A) Successive memory locations. B) Random memory locations. C) Alternate memory locations. D) None of the above. Show Answer Correct Answer: A) Successive memory locations. 25. A terminal node in a binary tree is called ..... A) Root. B) Branch. C) Child. D) Leaf. Show Answer Correct Answer: D) Leaf. ← PreviousNext →Related QuizzesClass 12 Computer Science Chapter 1 Data Structures Using Python Quiz 1Class 12 Computer Science Chapter 1 Data Structures Using Python Quiz 2Class 12 Computer Science Chapter 1 Data Structures Using Python Quiz 3Class 12 Computer Science Chapter 1 Data Structures Using Python Quiz 4Class 12 Computer Science Chapter 1 Data Structures Using Python Quiz 5Class 12 Computer Science Chapter 1 Data Structures Using Python Quiz 6Class 12 Computer Science Chapter 1 Data Structures Using Python Quiz 7Class 12 Computer Science Chapter 1 Data Structures Using Python Quiz 8Class 12 Computer Science Chapter 1 Data Structures Using Python Quiz 9Class 12 Computer Science Chapter 1 Data Structures Using Python Quiz 10 🏠 Back to Homepage 📘 Download PDF Books 📕 Premium PDF Books