Mind map
Bubble sort algorithms
Map content
Bubble sort algorithms
Pros and cons
- Cons
- Inefficient, especially in large lists or when the order is completely backwards as the amount of passes would be n-1, n representing the elements in the table
- Pros
- It can be a simple algorithm that can be implemented onto a computer
- it can be efficient to check if the list is in order as it would take one pass and would compare each number with the ones next to it
- Doesn't use much memory as it only uses the original list
- Cons
Method of algorithm
- 1. it looks at the first two items in a list
- 2. if the two items are in the correct order then it moves to the next pair. If they are in the wrong order they are swapped
- 3. move on to the next pair and repeat step 2 for each pair until you reach the end of the list this is called a pass
- 4. repeat the previous steps until there are no more swaps to be made and the list is ordered
Information
- Description
- Mind Map on Bubble sort algorithms, created by A R on 17/01/2019.
- Created by
- A R
- Views
- 1
- Rating