Data Structure and Algorithms (DSA) MCQs with answers Page - 5

Dear candidates you will find MCQ questions of Data Structure and Algorithms (DSA) here. Learn these questions and prepare yourself for coming examinations and interviews. You can check the right answer of any question by clicking on any option or by clicking view answer button.
Share your questions by clicking Add Question

A

Admin • 617.67K Points
Coach

Q. The following data structure allows deleting data elements from front and inserting at rear

  • (A) Stacks
  • (B) Queues
  • (C) Deques
  • (D) Binary search tree

A

Admin • 617.67K Points
Coach

Q. This data structure allows deletions at both ends of the list but insertion at only one end.

  • (A) Input-restricted deque
  • (B) Output-restricted deque
  • (C) Priority queues
  • (D) None of the above

A

Admin • 617.67K Points
Coach

Q. The following data structure is non-linear type

  • (A) Strings
  • (B) Lists
  • (C) Stacks
  • (D) None of the above

A

Admin • 617.67K Points
Coach

Q. The following data structure is linear type

  • (A) Strings
  • (B) Lists
  • (C) Queues
  • (D) All of the above

A

Admin • 617.67K Points
Coach

Q. To represent hierarchical relationship be- tween elements, the following data structure is not suitable

  • (A) Deque
  • (B) Priority
  • (C) Tree
  • (D) All of above

A

Admin • 617.67K Points
Coach

Q. A binary tree whose every node has either zero or two children is called

  • (A) Complete binary tree
  • (B) Binary search tree
  • (C) Extended binary tree
  • (D) None of above

A

Admin • 617.67K Points
Coach

Q. The depth of a complete binary tree is given by

  • (A) Dn = n log2n
  • (B) Dn = n log2n+1
  • (C) Dn = log2n
  • (D) Dn = log2n+1

A

Admin • 617.67K Points
Coach

Q. The complexity of Binary search algorithm is

  • (A) O(n)
  • (B) O(log )
  • (C) O(n log n)
  • (D) None of the above

A

Admin • 617.67K Points
Coach

Q. The complexity of Bubble sort algorithm is

  • (A) O(n)
  • (B) O (n2)
  • (C) O(n log n)
  • (D) None of the above

A

Admin • 617.67K Points
Coach

Q. When in order traversing a tree resulted E A C K F H D B G; the preorder traversal would return

  • (A) FAEKCDBHG
  • (B) FAEKCDHGB
  • (C) EAFKHDCBG
  • (D) FEAKDCHBG