Open In App

UGC-NET | UGC NET CS 2015 Jun – II | Question 4

Like Article
Like
Save
Share
Report

Consider the following statements:
(a) Depth – first search is used to traverse a rooted tree.
(b) Pre – order, Post-order and Inorder are used to list the vertices of an ordered rooted tree.
(c) Huffman’s algorithm is used to find an optimal binary tree with given weights.
(d) Topological sorting provides a labelling such that the parents have larger labels than their children.
Which of the above statements are true?

(A) (a) and (b)
(B) (c) and (d)
(C) (a), (b) and (c)
(D) (a), (b), (c) and (d)


Answer: (D)

Explanation:

  • Depth – first search is used to traverse a rooted tree. Correct
  • Pre – order, Post-order and Inorder are used to list the vertices of an ordered rooted tree. Correct
  • Huffman’s algorithm is used to find an optimal binary tree with given weights.
  • Correct
  • Topological sorting provides a labelling such that the parents have larger labels than their children.Correct

So, option (D) is correct.

Quiz of this Question


Last Updated : 10 May, 2018
Like Article
Save Article
Previous
Next
Share your thoughts in the comments
Similar Reads