Analysis of Algorithms and Computational Complexity Questions and Answers

Practice Mode
Showing 10 of 239 questions
Q171
Breadth-first traversal (BFS) is a method to traverse
  • A all successors of a visited node before any successors of any of those succcessors
  • B a single path of the graph as far it can go
  • C the graph using shortest path
  • D none of these
Answer: Option A
Q172
If a binary tree traversed in inorder, then numbers of the node are printed in ____ order
  • A ascending order
  • B desccending order
  • C randomly
  • D none of these
Answer: Option B
Q173
A list node representing an arc of a graph requires how many fields ?
  • A 3
  • B 2
  • C 4
  • D 1
Answer: Option D
Q174
Identity the correct statements about DFS traversal. I. It can be used to determine whether a graph is acyclic or not. II. It identify the connected component of an undirected graph III. traverses a single path of the graph until it visits a node with no successor.
  • A (i) and (iii)
  • B (ii), (iii)
  • C (i) and (ii)
  • D (i), (ii) and (iii)
Answer: Option A
Q175
Its appropriate to represent a queue as
  • A a circular list
  • B doubly linked list
  • C linear linked list
  • D array
Answer: Option B
Q176
Given two statements (i) Insertion of an element should be done at the last node in a circular list. (ii) Deletion of an element should be done at the last node of the circular list.
  • A Both are true
  • B Both are False
  • C first is true and second is false
  • D first is false and second is true
Answer: Option C
Q177
To insert a node in a circular list at rear position, it should be inserted at ____ of the queue
  • A Front position
  • B Front - 1 position
  • C Rear position
  • D Rear - 1 position
Answer: Option A
Q178
To free which of the following list traversing through the entire list is not necessary?
  • A Circular list
  • B Singly linked list
  • C Double linked list
  • D Both (b) and (c)
Answer: Option D
Q179
Graphs can be implemented using (i) arrays (ii) linked list (iii) stack (iv)queue
  • A (i), (ii) and (iv)
  • B (i), (ii) and (iii)
  • C (i) and (ii)
Answer: Option A
Q180
A header node to represent a graph node requires how many fields ?
  • A 3
  • B 2
  • C 4
  • D 5
Answer: Option D
Questions and Answers for Competitive Exams Various Entrance Test