in reply to Re: use regex to split sentence
in thread use regex to split sentence

In Perl6:

### <Perl6> @match = m:e/ X \d : .+? <before X \d | $ > /; ### </Perl6>
I do think they should give shortened versions of the <before > and <after > assertions. Oh well, maybe they'll throw it in.

(Note for onlookers: The colon within the regex is thrown in for a small bit of engine optimization, and actually also helps in detecting malformed strings.)

kelan


Perl6 Grammar Student