This is entirely an academic question. A guy asked me if it was possible to produce a regex to find duplicate words in a sentence. "Easy" I said......and I've now spent about 3 hours getting nowhere!
Can anyone help?
Using this sentence:
We are looking for a regex to output:
Any ideas?
Can anyone help?
Using this sentence:
Code:
this is some text with some duplicate words this is
We are looking for a regex to output:
Code:
some this is
Any ideas?