Mind map
Unit 1
Map content
Unit 1
SEARCHING ALGORITHMS
- Bubble sort
- Compare the first and second element from the list.
- If first number is more than second number, swap them.
- If not, go to second number and repeat.
- If first number is more than second number, swap them.
- In a list of n numbers, n^2 comparisons will need to be made
- This is slow and inefficient for more than a few items.
- Compare the first and second element from the list.
- Linear search
- Binary search
- Merge sort
- This method is fast but includes many steps to uses more memory space
- The elements are split into individual lists.
- The first elements in each list are compared
- The smallest is put into a new list
- Repeat until merged
- A recursive function is used to allow the lists to break down and merge.
- Repeat until merged
- The smallest is put into a new list
- The first elements in each list are compared
- Bubble sort
Information
- Description
- Mind Map on Unit 1, created by Ina Sharma on 10/10/2019.
- Created by
- Ina Sharma · Oct 2019
- Updated
- Dec 3, 2019
- Views
- 1
- Rating