$re = '[spectal]{9}'; $qr = qr/$re/o; # qr() # regcomp() # Compile the expression and remove this step # regcreset $data =~ m/$re/; # qr() # regcomp() # Re-use the expression # regcreset