What is the first index of an array?
What data structure stores items in order using indexes?
0
What is a string?
What does each node store besides a value?
A pointer (next)
The top node of a tree is called this.
Root
O(n) means this type of time.
linear
What operation adds an item to the end of a list in Python?
append()
A string that reads the same forward and backward is called this.
Palindrome
What do we call the first node?
head
What do we call nodes with no children?
leaves
O(1) time complexity is called this.
Constant time
This problem asks you to find two numbers that add up to a target.
Two sum
What data structure is commonly used to validate parentheses in a string?
Stack
Each node in a linked list contains a value and this.
Pointer (next reference)
In a binary tree, how many children can a node have max?
2
Which grows faster: O(n) or O(1)?
o(n)
If you scan an array once to find the max value, what is the time complexity?
O(n)
What built-in method or approach is often used conceptually to reverse a string?
Two pointers / reverse method
What do we call the last node in a linked list when its next is null?
Tail
Traversal order: Root → Left → Right is called this.
Preorder traversal
What is the time complexity of binary search?
O(log n)
What technique uses two pointers starting from opposite ends of an array?
Two-pointer technique
What is the output?
arr = [1,2,3]
print(arr[-1])
3
What algorithm detects a cycle using slow and fast pointers?
Floyd’s Cycle Detection
In a Binary Search Tree, where do values greater than the root go?
Right
Which is faster as input grows: O(n) or O(log n)?
O(log n)