Agoda interview question

breath first traversal on binary tree