In a decision tree, what does a leaf node represent?
Select an answer to reveal the explanation.
Short Explanation and Infographic
Here's the deal: walk a decision tree like a flowchart. Each internal node asks a question—"income > 50k?"—and sends you left or right. When the questions stop, you've hit a leaf: that's the answer the model gives you—spam or not, $120 predicted spend, whatever. Think of it like a choose-your-own-adventure book: intermediate pages branch; the last page is how the story ends. Exam trap: people mix leaf with split nodes, with "node next to the root," or with the root itself. Land it: leaf = terminal prediction. Boss asks why two customers got different scores—you follow their feature paths to different leaves. Pretty clean once you see it. Sketch one tiny tree and label root, splits, and leaves—you'll own this on test day.
Full explanation below image
Full Explanation
Decision trees are hierarchical models composed of a root node, internal decision nodes, and leaf or terminal nodes. Starting from the root, each internal node applies a test on one or more features and branches to child nodes accordingly. Recursion continues until a stopping criterion is met, such as maximum depth, minimum samples per node, pure class partitions, or pruning rules that remove splits which do not improve validation performance. Nodes where splitting stops are leaves. For classification, a leaf typically stores the majority class or class probability estimates among the training instances that fell into that region of feature space. For regression, a leaf stores a constant prediction such as the mean target value of those instances. Thus a leaf represents the final decision or output associated with a completed path through the tree.
Internal nodes represent the features and thresholds used to split data; they route examples but do not emit the model’s final answer while further children exist. Being adjacent to the root only identifies depth-one nodes, which may still split further and therefore are not defined as leaves merely by that adjacency. The root is the unique starting node that holds the full training set before partitioning; it sits at the opposite end of the structure from the leaves, except in the degenerate case of a trivial stump with no splits, which exams rarely intend when asking for the conceptual role of a leaf.
Understanding leaves matters for interpretability because each leaf corresponds to a conjunction of split conditions that a stakeholder can read as a rule. Leaf statistics also help diagnose overfitting when many pure leaves rest on tiny sample counts, and they matter in ensembles because forests and boosting methods aggregate many trees’ leaf predictions. Exam memory aid: the root starts the path, internal nodes ask questions, and leaves answer with the prediction. If an option describes a test used to branch, it is an internal node; if it describes the top node with the full dataset, it is the root; if it only says the node touches the root, the definition is incomplete. Best practice is to inspect leaf sample counts and prediction confidence so business users trust paths that end in stable leaves rather than sparse accidents created by over-deep growth.