Skip to content
Early access — you're among the first to try PYQLabs. Share feedback
Concept drill

leaf-nodes

GATE CSE & IT · Data Structures · 1995-2026

13
PYQs
77%
keyed
2
elite explanations
10
years appeared

Study anchor

Cormen et al. — Introduction to Algorithms (CLRS)

Algorithms, data structures, graph algorithms, complexity

Practice action

Start latest PYQ

PYQs in this concept

All concepts →
2026 PYQ

Consider a binary search tree (BST) with $n$ leaf nodes ( $n>0$ ). Given any node $V$, the key present in the node is denoted as $\operatorname{Val}(V)$. All the keys present in th...

mediumanswer keyelite explanation
2026 PYQ

Let $n$ be an odd number greater than 100 . Consider a binary minheap with $n$ elements stored in an array $P$ whose index starts from 1. Which of the following indices of $P$ do/d...

mediumanswer keyelite explanation
2024 PYQ

Consider a binary min-heap containing 105 distinct elements. Let k be the index (in the underlying array) of the maximum element stored in the heap. The number of possible values o...

mediumanswer keybasic explanation
2020 PYQ

Consider the array representation of a binary min-heap containing 1023 elements. The minimum number of comparisons required to find the maximum in the heap is _______.

mediumbasic explanation
2015 PYQ

A binary tree $$T$$ has $$20$$ leaves. The number of nodes in $$T$$ having two children is _______________.

easy
2015 PYQ

Consider a binary tree $$T$$ that has $$200$$ leaf nodes. Then, the number of nodes in $$T$$ that have exactly two children are ________.

easy
2014 PYQ

Consider the pseudocode given below. The function Dosomething () takes as argument a pointer to the root of an arbitrary tree represented by the leftMostChild-rightSibling represen...

mediumanswer key
2007 PYQ

Consider the following C program segment where CellNode represents a node in a binary tree: struct CellNode { struct CellNOde *leftChild; int element; struct CellNode *rightChild;...

easyanswer key
2006 PYQ

In a binary tree, the number of internal nodes of degree 1 is 5, and the number of internal nodes of degree 2 is 10. The number of leaf nodes in the binary tree is

easyanswer key
2006 PYQ

In a binary max heap containing n numbers, the smallest element can be found in time

easyanswer keybasic explanation
2005 PYQ

In a complete k-ary tree, every internal node has exactly k children. The number of leaves in such a tree with n internal nodes is

easyanswer key
2002 PYQ

The number of leaf nodes in a rooted tree of n nodes, with each node having 0 or 3 children is:

easyanswer key
1995 PYQ

A binary tree T has n leaf nodes. The number of nodes of degree 2 in T is:

easyanswer key