Data Structures and Algorithms Online Test - 1
Question: 1
Name the tree in which, for every node, the height of left sub tree and height of right sub tree can differ by at most one
(A) AVL tree
(B) B-tree
(C) Threaded tree
(D) Complete tree
Ans: A
AVL tree
Question: 2
Which of the following statements about a binary tree is correct?
(A) No binary tree is both complete and full
(B) Every full binary tree is also a complete binary tree
(C) Every complete binary tree is also a full binary tree
(D) Every binary tree is either complete or full
Ans: B
Every full binary tree is also a complete binary tree
Question: 3
What is the worst-case time for binary search finding a single item in an array?
(A) Quadratic time
(B) Linear time
(C) Logarithmic time
(D) Constant time
Ans: C
Logarithmic time
Question: 4
If a binary tree satisfies shape and order property, it is known as
(A) Rooted tree
(B) Heap
(C) Sequential search tree
(D) Binary search tree
Ans: B
Heap
Question: 5
With an array-based stack, the algorithm for push is
(A) Increment top and add item to the new top location
(B) Add item to the top location and then increment top
(C) Return the top item and increment top
(D) Return the top item and decrement top
Ans: A
Increment top and add item to the new top location
- Data Structure MCQ Questions and Answers
- Data Structure Multiple Choice Questions and Answers Pdf
- Data Structure Objective Questions and Answers Pdf
- Top 150+ Data Structure Quiz Questions and Answers
- Data Structures and Algorithms Online Test
- Data Structure Lab Exam Practical Viva Questions and Answers
- Data Structures and Algorithms MCQs- Multiple Choice Questions Quiz Pdf
Dc generator questions and answers pdf More
DC Generator Questions and Answers Pdf More
Electromagnetic Induction Quiz Questions and Answers More
Basic Electronics Quiz Questions with Answers Pdf More
Wireless Communication MCQ Questions with Answers More
Problems on Ages TNPSC Previous Year Questions More
TNPSC Group 1, 2, 2a, 4 Union State Territory GK Quiz Questions and Answers More
Top 1,000+ Computer Abbreviations for Competitive Exams 2020-2021 More
Communication System Multiple Choice Questions and Answers Pdf More
Oracle 12c DBA Interview Questions and Answers More