Efficiency of algorithms (Edexcel GCSE Computer Science): Flashcards
📚Flashcards
Practise the cards
15 cards from this deck
ShowHide
Practise the cards
15 cards from this deck
Factors affecting algorithm efficiency
Factors affecting algorithm efficiency
Type of data, whether sorted, time available, and usage frequency
How linear search works
How linear search works
Checks each item one by one from start to end
When to use linear search
When to use linear search
Unsorted list, short list, or won't search often
Linear search best case scenario
Linear search best case scenario
Item is the very first one in the list
Linear search worst case scenario
Linear search worst case scenario
Item is last in list or not there at all
Binary search critical requirement
Binary search critical requirement
List must already be sorted
How binary search eliminates data
How binary search eliminates data
Divides list in half each time
When to use binary search
When to use binary search
Long list, searched frequently, already sorted
How bubble sort works
How bubble sort works
Compares adjacent items, swaps if wrong order
When to use bubble sort
When to use bubble sort
Small list, simple programming, memory limitations
Bubble sort best case scenario
Bubble sort best case scenario
List is already sorted
Merge sort approach type
Merge sort approach type
Divide and conquer
When to use merge sort
When to use merge sort
Long lists, consistent performance, extra memory OK
Algorithms that handle long lists well
Algorithms that handle long lists well
Binary search and merge sort
Algorithms using minimal extra memory
Algorithms using minimal extra memory
Linear search and bubble sort
