Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re^5: Help me beat NodeJS

by RichardK (Parson)
on Feb 13, 2016 at 22:54 UTC ( #1155185=note: print w/replies, xml ) Need Help??


in reply to Re^4: Help me beat NodeJS
in thread Help me beat NodeJS

If you just looking for a plain string not a regex, then it should be quicker to use index

while (my $line = <$fh> ) { if (index($line,$pattern) != -1 ) { ... } }

Replies are listed 'Best First'.
Re^6: Help me beat NodeJS
by marioroy (Vicar) on Feb 13, 2016 at 23:41 UTC

    yes, ++

      Very nice, thank you.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (5)
As of 2020-05-27 23:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If programming languages were movie genres, Perl would be:















    Results (162 votes). Check out past polls.

    Notices?