http://www.perlmonks.org?node_id=173113


in reply to Code explanation needed (was: What does this mean)

Line 1:
Collect all the lines that match the regex from the array @file, it's a dumb way of doing it but hey..

Line 2:
Needs a $ at the start, stores the regex in a hash of non_matches unless there are matches in the @matches array.

Line 3:
Again needs a $ at the start. Stores the regex in a hash if there are duplicates.

It could be written nicer.. ;)

--

Brother Frankus.

¤