1.Easy
In a tree, what are sibling nodes?
- ANodes that have no children
- BNodes that share the same parent
- CNodes at the same depth in different subtrees
- DA node and its parent
2.Easy
What defines a binary tree?
- AEvery node has at most two children
- BEvery node stores a binary number
- CEvery node has exactly two children
- DThe tree has exactly two levels
3.Easy
In a singly linked list, each node contains:
- AOnly data
- BData and references to all other nodes
- CData and an index
- DData and a reference to the next node
4.Medium
In a hash table using open addressing, what is the maximum possible load factor?
- A1
- B2
- CThere is no maximum
- D0.5
5.Medium
A circular buffer (ring buffer) is commonly used to implement:
- AA binary search tree
- BA hash function
- CA fixed-size queue
- DA graph traversal
6.Medium
How long does a search for a word of length L take in a trie with a fixed alphabet?
- AO(L), independent of how many words are stored
- BO(L × n)
- CO(n), where n is the number of words
- DO(log n), where n is the number of words
7.Hard
A Bloom filter can answer "is this element in the set?" with:
- AAnswers only for numbers
- BPossible false positives but no false negatives
- CPossible false negatives but no false positives
- DExact answers always
8.Hard
How long does it take to search for an arbitrary key in a binary min-heap of n elements?
- AO(log log n)
- BO(1)
- CO(log n)
- DO(n)
Answer key
- 1. B · Nodes that share the same parent
- 2. A · Every node has at most two children
- 3. D · Data and a reference to the next node
- 4. A · 1
- 5. C · A fixed-size queue
- 6. A · O(L), independent of how many words are stored
- 7. B · Possible false positives but no false negatives
- 8. D · O(n)
Full step-by-step solutions: practise this topic on examproblems.com.