Data Structure
Linear Search
learn datastructure by example of linear search algorithm
G
Geekboots4/17/2021
0 views
linear-search-algorithm.cC
# Input: Array D, integer key
# Output: first index of key in D,
# or -1 if not found
For i = 0 to last index of D:
if D[i] equals key:
return i
return -1data structurealgorithmlinear search algorithmlinear search
Loading comments...







