started chaining script with finding repeated matches|