This is javascript function for finding the word in array's.