Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re^5: What's the "...0" mean?

by morgon (Priest)
on Oct 15, 2010 at 23:24 UTC ( [id://865587]=note: print w/replies, xml ) Need Help??


in reply to Re^4: What's the "...0" mean?
in thread What's the "...0" mean?

That is a good example.

But in the original question

perl -ne 'print if s/.*?(?=abc)//...2' input.txt
the flip-flop is true on the first line (the substitution) and remains to be true on the second line (the comparison with line number).

But should it then not remain false for the rest of the file resulting in no more lines being printed?

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (7)
As of 2024-04-19 11:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found