WBJECA 2025 Computer PYQ — Which of the following traversal techniques lists the nodes of a … | Mathem Solvex | Mathem Solvex
Tip:A–D to answerE for explanationV for videoS to reveal answer
WBJECA 2025 — Computer PYQ
WBJECA | Computer | 2025
Which of the following traversal techniques lists the nodes of a binary search tree in ascending order?
Choose the correct answer:
A.
Inorder
(Correct Answer)
B.
Preorder
C.
Postorder
D.
None of these
Correct Answer:
Inorder
Explanation
Correct Option: (A) Inorder
Explanation
A Binary Search Tree (BST) is a specialized data structure where, for any given node, all elements in the left subtree are smaller than the node, and all elements in the right subtree are greater.
Inorder Traversal: This technique follows the pattern: Left Subtree → Root → Right Subtree. Because it always visits the smaller (left) nodes before the root and the larger (right) nodes after, it naturally retrieves data in non-decreasing (ascending) order.
A Binary Search Tree (BST) is a specialized data structure where, for any given node, all elements in the left subtree are smaller than the node, and all elements in the right subtree are greater.
Inorder Traversal: This technique follows the pattern: Left Subtree → Root → Right Subtree. Because it always visits the smaller (left) nodes before the root and the larger (right) nodes after, it naturally retrieves data in non-decreasing (ascending) order.