Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer

Re^2: perl6 phasers and a 1 liner

by Laurent_R (Canon)
on Feb 13, 2018 at 22:39 UTC ( #1209092=note: print w/replies, xml ) Need Help??

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.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1209092]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (8)
As of 2018-08-18 17:55 GMT
Find Nodes?
    Voting Booth?
    Asked to put a square peg in a round hole, I would:

    Results (185 votes). Check out past polls.