Mapa mental
Searching Algorithms
Conteúdo do 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.
Informações
- Descrição
- A level Computing Mapa Mental sobre Searching Algorithms, criado por Sarhaan Qurban em 25-01-2018.
- Criado por
- Sarhaan Qurban
- Visualizações
- 0
- Avaliação