Given a decision tree that is 4 levels in height, with each node producing 4 possible results, what is the max number of leaves?
64 Leaves.
Explanation ::
Level 1 :: Root node is level 1 in a decision tree.
Level 2 :: As per question, each node is producing 4 possible results it means 2nd level which is produced by root will have ( 1 * 4 = 4) Nods.
Level 3 :: As each node produces 4 results and level 2 is having 4 nodes so total nodes for level 3 = no of results produced by level 2 ie 4 * 4 = 16
Level 4 :: As level 3 having 16 nodes so it will produce 16 * 4 = 64 result nodes which are nothing but leaves of level 4 decision tree.
Get Answers For Free
Most questions answered within 1 hours.