added pattern finding in a string