Create searchAlgo.c

Old version of the code.