Zebra0.com

cpp searchThe sequential search code

The sequential search code

We would like to search an unsorted list such as the one below for a particular name. We will use a sequential search because the list is not sorted.

index names years
0 Jay 1974
1 Debbie 1976
2 John 1918
3 Greg 1954
4 Carol 2011
5 Sam 2000