How the Binary Search Algorithm Works. (3 marks)
Explain how the binary search algorithm works on a sorted list.
How the Binary Search Algorithm Works. (3 marks) Read More »
Explain how the binary search algorithm works on a sorted list.
How the Binary Search Algorithm Works. (3 marks) Read More »
Compare and contrast linear and binary search algorithms.
Compare and Contrast Linear and Binary Search Algorithms. (6 marks) Read More »
What does the term ‘time complexity’ tell you about an algorithm and why is it important to know the time complexity when comparing two algorithms?
Time Complexity Basics (2 marks) Read More »
If you have a large database and need to find records quickly, would you choose a linear search or a hashed search method? Explain your answer.
Efficient Search in a Database (3 marks) Read More »
A developer used two different sorting algorithms to arrange a list of numbers in ascending order. Algorithm A is a selection sort (time complexity of O(n^2)), and Algorithm B is a quicksort (time complexity of O(n log n)). Which algorithm is likely to be more time-efficient for sorting large datasets and why?
Algorithm Efficiency Analysis (2 mark) Read More »
Explain why an iterative algorithm might be more time-efficient than a recursive algorithm for calculating numbers in a sequence.
Algorithm Efficiency Understanding (2 marks) Read More »
If you have a sorted list and you need to find a specific item, would you choose a linear search or a binary search? Explain your choice.
Search Algorithm Selection (2 marks) Read More »
Decomposition is a crucial step in problem-solving. Explain why it is important to decompose complex problems.
Why Decomposition (3 marks) Read More »
In computer science, what is meant by ‘abstraction’? Give an example to illustrate your explanation.
Abstraction Meaning (3 marks) Read More »
Identify the input in the following simple algorithm: OUTPUT ‘What is your name?’ name
Input Identification (1 mark) Read More »