in reply to Re^4: Extract Multiple Lines from the End of a multi-line string
in thread Extract Multiple Lines from the End of a multi-line string

Presumably followed by \z? Your last line doesn't end with \n, and that's a bad use of capturing parens.

Replies are listed 'Best First'.
Re^6: Extract Multiple Lines from the End of a multi-line string
by NateTut (Deacon) on Oct 17, 2008 at 17:03 UTC
    Yes it was followed by /z. Why is that bad use of capturing parens?

      What do you think /(...){5}/ captures? The parens are there for grouping, not capturing. If you wanted to capture the five things, you'd use /((?:...){5})/

      Note: New features in Perl 5.10 may make /(...){5}/ useful

        Thanks, that helped clear it up.