fixed find word funct, elements of interface and validation of input