Data Structure Sequential Search Algorithm.


Data Structure Algorithm for  Sequential Search  pseudo-code.
After knowing and completely understanding this algorithm for  Sequential Search . You will be able to write a Data Structure Program for  Sequential Search  in any language. The basic ideology and idea behind all the programs will be same. Yes the programs will differ according to the syntax and semantics of the language. Mumbai University MCA College Algorithm



 Algorithm SeqSearch(list, last,target,location)
1 set current to 0
2 set found to FALSE
3 loop (current < endList AND
list[current] <> target)
1 increment current
4 end loop
5 set location to current
6 if (list[current] = target)
1 set found to TRUE
7 end if
End SeqSearch


Hope this Algorithm is useful to you in some sense or other. Keep on following this blog for more Mumbai University MCA College Programs. Happy Programming and Studying.

No comments:

Post a Comment