Linear Search

Linear search finds the location of an item within an unordered array (collection of data). The algorithm starts at the beginning of the array and checks to see if the first item is the one that is being searched for - if not it moves onto the next item and repeats the process until it finds the desired data.

In terms of performance it can have the best case (finding the desired item first time) and worst case scenario (fining the desired item last). 

The major benefit is that it can be ran on an unordered array, however the average case time may be too impractical for larger arrays

The performance limitation of linear search may not be as apparent in a small array, however will become apparent if you are searching for an item in one with millions of entries.


Included in the following specifications:
Edexcel GCSE Computer Science
OCR GCSE Computer Science