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


in reply to Re: perl6 phasers and a 1 liner
in thread perl6 phasers and a 1 liner

Another problem is that you have a -ne (i.e. run once for every line) but you use the lines sub in your code, which will immediately give you all lines as one list.
You seem to have missed that the code is using two different files. The OP uses the .lines IO method to read patternFile.txt in the BEGIN block, and the -ne command line option to read searchFile.txt.

Replies are listed 'Best First'.
Re^3: perl6 phasers and a 1 liner
by Anonymous Monk on Feb 14, 2018 at 02:01 UTC
    i was actually referring to the lines sub, not the lines method. both occur in the code, and the part that uses the sub is the one that is the problem.