Help for this page

Select Code to Download


  1. or download this
    if ($file =~ /-\(lala\)-/) { ...
    
  2. or download this
    my $skip = "/-\(lala\)-/";
    if ($file =~ /$skip/)
    
  3. or download this
    my $skip = "/-\\(lala\\)-/";  # protect the backslash for itself
    if ($file =~ /$skip/) { ...
    
  4. or download this
    my $skip = '/-\(lala\)-/';  # use singe quotes
    if ($file =~ /$skip/) { ...
    
  5. or download this
    my $skip = "/-(lala\-/";  
    if ($file =~ /\Q$skip/) { ... # quote it in the regexp
    
  6. or download this
    my $skip = qr/-\(lala\)-/;    # use precompiled regexps
    if ($file =~ /$skip/) { ...