Is there a different way to concatenate variables in Perl?
I accidentally wrote the following line of code:
print \"$linenumber is: \\n\" . $linenumb
You can backslash the $ to print it literally:
$
print "\$linenumber is: \n" . $linenumber;
That prints what you were expecting. You can also use single quotes if you don't want Perl to interpolate variable names, but then the "\n" will be interpolated literally.
"\n"