Comparison of Sorting Algorithms: Bubble, Selection, Insertion, Merge, and Quick Sort

0.0(0)
studied byStudied by 0 people
full-widthCall with Kai
GameKnowt Play
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/4

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

5 Terms

1
New cards

Bubble Sort

Best: O(n), Average: O(n2), Worst: O(n2), Space Complexity: O(1), Stable: Yes, Best Use Cases: Small datasets, educational purposes

2
New cards

Selection Sort

Best: O(n2), Average: O(n2), Worst: O(n2), Space Complexity: O(1), Stable: No, Best Use Cases: Small datasets, memory-constrained environments

3
New cards

Insertion Sort

Best: O(n), Average: O(n2), Worst: O(n2), Space Complexity: O(1), Stable: Yes, Best Use Cases: Small or partially sorted datasets

4
New cards

Merge Sort

Best: O(nlogn), Average: O(nlogn), Worst: O(nlogn), Space Complexity: O(n), Stable: Yes, Best Use Cases: Large datasets, linked lists

5
New cards

Quick Sort

Best: O(nlogn), Average: O(logn), Worst: O(n2), Space Complexity: O(nlogn), Stable: No, Best Use Cases: In-memory sorting, general-purpose