Help for this page

Select Code to Download


  1. or download this
    my @list = split /,/, $thestring;
    if(grep { $_ == $thecheck } @list) {
    ...
    if($set{$thecheck}) {
        print "Found it!\n";
    }
    
  2. or download this
    if($thestring =~ /(?:^|,)$thecheck(?=,|$)/) { ... }
    
  3. or download this
    if($thestring =~ /(?<![^,])$thecheck(?![^,])/) { ... }