word match index index index bfigure afirst stepbsecond step cmatch occurred algorithm any(word,match prewordmatch postindex representing match location if occured- otherwise for to word length while word[iwhitespace - + end while for index to match length while match[indexwhitespace index index end while if match[indexword[ return index end if end for end for return - end any summary we hope that the reader has seen how fun algorithms on string data types are strings are probably the most common data type (and data structure remember we are dealing with an arraythat you will work with so its important that you learn to be creative with them we for one find strings fascinating simple google search on string nuances between languages and encodings will provide you with great number of problems now that we have spurred you along little with our introductory algorithms you can devise some of your own