Mapa mental
Searching Algorithms
Contenido del mapa
Searching Algorithms
Binary search
- Finding an item in a ordered list only
- Completely divides the proportion of the list that could contain the item by half until it is narrowed down to one.
- Worst case time complexity O( log n)
- Best case scenario O(1)
- Finding an item in a ordered list only
Linear search
- Finding an item in a list which is sorted or unsorted
- Sequentially checks each element in the list for the target value until all elements have been searched or the element is found
- Worst case complexity O(n)
- Best case scenario O(1)
- Finding an item in a list which is sorted or unsorted
Sorting an array takes time in itself, in terms of efficiency binary will always be slower than linear.
Información
- Descripción
- A level Computing Mapa Mental sobre Searching Algorithms, creado por Sarhaan Qurban el 25/01/2018.
- Creado por
- Sarhaan Qurban
- Visitas
- 0
- Valoración