
Algorithms Trivia Questions
Explore the step-by-step methods that help computers solve problems, from sorting and searching to navigating networks. See how famous algorithms work and what makes them efficient.
Algorithms trivia questions and answers
Which sorting method repeatedly compares neighboring items and swaps them when they are out of order?
Show answerHide answer
Bubble sort
Its simple passes can be easy to understand, but its worst-case running time grows quadratically with the number of items.
Which sorting algorithm divides a list into smaller parts, sorts those parts, and then merges them?
Show answerHide answer
Merge sort
Merge sort runs in O(n log n) time, and its stable behavior can preserve the order of equal-key items.
Which sorting algorithm partitions items around a chosen pivot, then sorts the resulting sections?
Show answerHide answer
Quicksort
Its average running time is O(n log n), though a poor sequence of pivots can lead to quadratic time.
What search method repeatedly halves the remaining search interval and requires the data to be sorted?
Show answerHide answer
Binary search
On a sorted array, it can find an item in O(log n) comparisons, even when the array is very large.
What search method checks items in sequence until it finds a match or reaches the end?
Show answerHide answer
Linear search
It works on unsorted data and needs no extra indexing structure, but may inspect every item.
How to play
- • Each game has 10 questions. Before each one you see only a hint about its topic.
- • Choose what it’s worth, from $1 to $20. Each value can only be used once per game.
- • Type your answer. Small spelling mistakes are fine. Get it right and you win that amount.




