Comparing Algorithms Flashcards
1
Q
Efficiency
A
Amount of resources used by an algorithm, which can affect how long it runs
2
Q
Time complexity of an algorithm
A
How fast the algorithm runs
3
Q
Space complexity of an algorithm
A
How much memory the algorithm needs
4
Q
Worst case complexity
A
When we happen to choose an input that requires the longest time or greatest workload
5
Q
Best case complexity
A
When we choose an input that requires the shortest time or smallest workload
6
Q
Average case complexity
A
Calculated by averaging the times for every possible input