Merge Sort (OCR A-Level Computer Science): Flashcards
📚Flashcards
Practise the cards
12 cards from this deck
ShowHide
Practise the cards
12 cards from this deck
Approach used by Merge Sort
Approach used by Merge Sort
Divide-and-conquer
3 main steps of Merge Sort
3 main steps of Merge Sort
Divide, Conquer, Merge
What the Divide step does in Merge Sort
What the Divide step does in Merge Sort
Split the array into two halves
What the Conquer step does in Merge Sort
What the Conquer step does in Merge Sort
Recursively sort each half
What the Merge step does in Merge Sort
What the Merge step does in Merge Sort
Combine two sorted halves into single sorted array
Merge Sort time complexity (best, worst, average)
Merge Sort time complexity (best, worst, average)
Merge Sort space complexity
Merge Sort space complexity
Is Merge Sort stable
Is Merge Sort stable
Yes
What 'stable' means for sorting algorithms
What 'stable' means for sorting algorithms
Maintains relative order of equal elements
Base case for Merge Sort recursion
Base case for Merge Sort recursion
Array size is 1 or less
Memory requirement of Merge Sort
Memory requirement of Merge Sort
Requires additional memory for temporary arrays
Merge Sort effectiveness on large data sets
Merge Sort effectiveness on large data sets
Particularly effective/works well
