good chemistry is complicated, and a little bit messy -LW |
|
PerlMonks |
Re: regex match multiple lineby ww (Archbishop) |
on Nov 26, 2014 at 22:06 UTC ( [id://1108511]=note: print w/replies, xml ) | Need Help?? |
The first thing that leaps at /me is the inappropriate escaping of the sigil in the regex. The next is that you ask would-be helpers to take at face value -- that is, without code to back up the claim -- that "(you) created a hash...." ... which, for the limited purpose of this WAG, I'll take for fact, since it's a plausible sample of a hash.
But the next big ugly is is that you haven't given us enough with which to confidently jump off a cliff. ... but here goes anyway (sure hope the water's deep down there) (code and output updated for clarity):
Execution:
Note the use of qr in the declaration of the string you're trying to use (I think -- sorry, Xtal ball is gebroke!) as a regex... and, of course, the use of strict, warnings, etc. ...and that the irony in the messages IS intentional. :-)
In Section
Seekers of Perl Wisdom
|
|