adplus-dvertising
frame-decoration

Question

From the following code identify the which traversal of a binary tree is this __________

//if node has left child
order(node.left)
//if node has right child
order(node.right)
visit(node)

a.

Inorder traversal

b.

preorder traversal

c.

postorder traversal

d.

Euler tour traversal

Posted under Discrete Mathematics

Answer: (c).postorder traversal

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. From the following code identify the which traversal of a binary tree is this __________ //if node has left child order(node.left) //if node has right child...

Similar Questions

Discover Related MCQs

Q. What is the minimum height for a binary search tree with 60 nodes?

Q. From the following code identify the which traversal of a binary tree is this __________
function traversal(node)

{
//Input:root node of the tree
//Output:None
visitLeft(node)
//if node has left child
traversal(node.left)
visit_Below(node)
//if node has right child
traversal(node.right)
visitRight(node)
}

Q. For the expression (7-(4*5))+(9/3) which of the following is the post order tree traversal?

Q. The time complexity of calculating the sum of all leaf nodes in an n-order binary tree is __________

Q. An immediate application of a Depth First Search traversal is __________

Q. Breadth First Search traversal of a binary tree finds its application in __________

Q. Worst case complexity of Breadth First Search traversal __________

Q. Evaluation of expression a/b+c*d-e in postfix notation.

Q. Evaluation of 4*5+3/2-9 in prefix notation.

Q. What is the output of the following if funct1(7)?

Q. Infix to prefix conversion can be done using __________

Q. Conversion from prefix to postfix expression can be done _______________

Q. What is the postfix expression of 9+3*5/(10-4)?

Q. What is the postfix expression of (A+B)-C*(D/E))+F?

Q. Convert the following expression into prefix notation.

(g-(f^e/d+c)-ba)

Q. What is the postfix expression of the given expression, (2*4-(5+7/3^4)-8)10?

Q. Prefix expression can be evaluated _________

Q. Spanning trees have a special class of depth-first search trees named _________

Q. If the weight of an edge e of cycle C in a graph is larger than the individual weights of all other edges of C, then that edge ________

Q. For every spanning tree with n vertices and n edges what is the least number of different Spanning trees can be formed?