in reply to string matching

FunkyMonk's suggestion of using quotemeta (and \Q) should work well. If you really are looking only for literal strings, though, it might be better to use index for that. Also, your original matching pattern contains a dot (/./) which will match any character (except newline), so /1.1/ will also match "1x1", for example. You need to quote the dot to make it literal (i.e., /\./).