Company: Zomato Eternal_10oct
Difficulty: hard
Consider the binary tree below, where node 1 is the root, nodes 2 and 3 are its children, nodes 4 and 5 are the children of 2, nodes 6 and 7 are the children of 3, node 8 is the left child of 4, and node 9 is the right child of 7. The expected output of the zigzag traversal is: 1 3 2 4 5 6 7 9 8 Choose the answer that corrects the logical errors in the code. Note: Assume a class named TreeNode is