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

Re: Pattern problem

by spadacciniweb (Deacon)
on Jan 27, 2006 at 14:21 UTC ( #525976=note: print w/replies, xml ) Need Help??


in reply to Pattern problem

Why
$text =~ /Host System (?!#)/
??

Correct:
$text =~ /Host System [^#]/

Replies are listed 'Best First'.
Re^2: Pattern problem
by ikegami (Pope) on Jan 27, 2006 at 18:51 UTC

    $text =~ /Host System (?!#)/ is correct too. However, [^#] is probably faster and an acceptable replacement in this case.

    The problem is
    if $text =~ /Host System (?!#)/ next;
    was used instead of
    if ($text =~ /Host System (?!#)/) { next; }
    or
    next if ($text =~ /Host System (?!#)/);
    or
    next if $text =~ /Host System (?!#)/;

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://525976]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (13)
As of 2017-01-16 16:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you watch meteor showers?




    Results (151 votes). Check out past polls.