Suitability of Algorithms (OCR A-Level Computer Science): Flashcards
📚Flashcards
Practise the cards
15 cards from this deck
ShowHide
Practise the cards
15 cards from this deck
Two metrics for measuring algorithm efficiency
Two metrics for measuring algorithm efficiency
Execution time (speed) and space (memory usage)
Time complexity definition
Time complexity definition
Measures time taken as function of input size
Space complexity definition
Space complexity definition
Measures memory used during execution
time complexity name
time complexity name
Constant time
time complexity name
time complexity name
Logarithmic time
time complexity name
time complexity name
Linear time
time complexity name
time complexity name
Quadratic time
time complexity name
time complexity name
Exponential time
What space complexity includes
What space complexity includes
Input data, temporary variables, call stack
Algorithm characteristic needed for large inputs
Algorithm characteristic needed for large inputs
Lower time complexity
Bubble Sort time & space complexity
Bubble Sort time & space complexity
time, space
Merge Sort time & space complexity
Merge Sort time & space complexity
time, space
Binary Search time complexity
Binary Search time complexity
Linear Search suitability for data type
Linear Search suitability for data type
Works on unsorted data
More memory-efficient factorial approach
More memory-efficient factorial approach
Iterative: space vs recursive space
