I am working on some regex crosswords. I decided to take one of the expressions and apply it to some real life text (using Notepad++) to see exactly what happens. It's left me baffled!
The regex I am matching is:
(.)+\1
The text I applied it to is:
Business Parks - Research business parks in the Reading area with conference capabilities
Green Park - expensive and no advertising allowed except via their newsletter
Arlington Business Park - no facility Thames Valley Science Park (TVSP) -
Sleep
The matches I get are (notice how matches can be mid-word):
Business Parks - Research business
Green Park - expensive and no advertising allowed except via their newslett
Arlington Business
Thames Vall
Slee
I'd be very grateful if someone could walk me through what is going on here. I anticipated a bit some sort of result to where repeated characters get matched due to the '\1'. However, I am particularly stumped why 'Green' gets evaluated and still continues up to 'newslett'.