## Question 1 What is the output if the following number of nodes and edges are given as input? n = 4\ edges = [[1, 0], [1, 2], [1, 3]] ### Options 1. [0] Incorrect ---------------------------- 2. [1] Correct The following minimum height tree is formed by selecting node 1 as the root: ```shell 1 /|\ 0 2 3 ``` ---------------------------- 3. [0, 1] Incorrect ---------------------------- 4. [1, 3] Incorrect ---------------------------- --------------------------------------------- ## Question 2 What is the output if the following number of nodes and edges are given as input? n = 5\ edges = [[0, 1], [1, 2], [2, 3], [2, 4]] ### Options 1. [1] Incorrect ---------------------------- 2. [4] Incorrect ---------------------------- 3. [1, 2] Correct 1. The following minimum height tree is formed by selecting node 1 as the root: ```shell 1 / \ 0 2 / \ 3 4 ``` 2. The following minimum height tree is formed by selecting node 2 as the root: ```shell 2 /|\ 1 3 4 | 0 ``` ---------------------------- 4. [1, 4] Incorrect ---------------------------- --------------------------------------------- ## Question 3 What is the output if the following number of nodes and edges are given as input? n = 6\ edges = [[0, 1], [0, 2], [0, 3], [3, 4], [3, 5]] ### Options 1. [0] Incorrect ---------------------------- 2. [2] Incorrect ---------------------------- 3. [0, 2] Incorrect ---------------------------- 4. [0, 3] Correct 1. The following minimum height tree is formed by selecting node 0 as the root: ```shell 0 /|\ 1 2 3 / \ 4 5 ``` 2. The following minimum height tree is formed by selecting node 3 as the root: ```shell 3 /|\ 0 4 5 / \ 1 2 ``` ---------------------------- ---------------------------------------------