Palo Alto Networks interview question

Handling tree, calculation the big O.