Consider the following statements:
- Depth-first search is used to traverse a rooted tree
- Pre-order, Post-order and Inorder are used to list the vertices of an ordered rooted tree.
- Huffman's algorithm is used to find an optimal binary tree with given weights
- Topological sorting provides a labelling such that the parents have larger labels than their children
Which one of the above statements is true?
- $\text{i and ii}$
- $\text{iii and iv}$
- $\text{i, ii, and iii}$
- $\text{i, ii, iii, and iv}$