Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Extended Patterns of Regular Expressions

by OM_Zen (Scribe)
on Feb 19, 2003 at 22:47 UTC ( #236866=perltutorial: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my $cust_code  = “SILICONEXSiliconex-wafers”;
    
    ...
    __END__
    [SILICONEXSiliconex-wafers]
    
  2. or download this
    
    my $pattern = "(?i)SILICONEXsiliconex-wafers";
    ...
    
                                 }
    
  3. or download this
    
    
    ...
         (?i) as /i for case sensitive pattern notation 
              or a combination of the flags
    
  4. or download this
    
    my $sub_contract="SILICONEXsiliconex-wafers ^M NOTE1-- a shipment in ^
    +M backlog calc note for 
    ...
    [ for 
    the shipping dates the contract is delivered ] [ 1 a shipment in  back
    +log calc note ]
    
  5. or download this
        s/(?m:(\^M|--))/ /g 
    
  6. or download this
    
    (?=     indicates a positive forward(look_ahead) assertion
    ...
    (?<=    indicates a positive backward(look_behind) assertion
    (?<!    indicates a negative backward(look_behind) assertion
    
  7. or download this
         $product = "MOTOROLAx|xx|xx|x01-01-1900x|xYx|x";
         $product =~ s/x\|xx\|x/x\|x x\|x/g;
    ...
    
         [ MOTOROLAx|x x|xx|x01-01-1900x|xYx|x ]
    
  8. or download this
     [ MOTOROLAx|x x|xx|x01-01-1900x|xYx|x ]
    
  9. or download this
    $product = "MOTOROLAx|xx|xx|x01-01-1900x|xYx|x";
    $product =~ s/(?<=\|)xx(?=\|)/x x/g;
    ...
    
    [ MOTOROLAx|x x|x x|x01-01-1900x|xYx|x ]
    
  10. or download this
    $product = "MOTOROLAx|xx|xx|x01-01-1900x|xYx|xx";
    $product =~ s/(?<=\|)xx(?=(\||$)/x x/g;
    ...
    
    
    [ MOTOROLAx|x x|x x|x01-01-1900x|xYx|x x ]
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (10)
As of 2015-07-06 16:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (77 votes), past polls