You can save yourself a bit of typing effort by using forward slashes (c:/path/to/file.txt) instead of doubled backslashes (c:\\path\\to\\file.txt). This works most of the time in Perl under Win32.
The only time I've encountered problems with it is passing these strings to CMD.EXE through backticks or system and similar mechanisms. There may be others I haven't encountered.
In reply to Re: using a scalar in a regex with backslashes
by BrowserUk
in thread using a scalar in a regex with backslashes
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |