Re: Question about escaped characters

2007-12-12 Thread Chas. Owens
On Dec 11, 2007 7:33 PM, Why Tea <[EMAIL PROTECTED]> wrote: > my $s = "This is a string\nThis is line 2\n"; > print $s; > > The "\n" is interpreted as newline in the code above. But if the > string (i.e. $s) is in a file, it will be printed literally as "\n" - > how do I get Perl to treat it as new

Question about escaped characters

2007-12-12 Thread Why Tea
my $s = "This is a string\nThis is line 2\n"; print $s; The "\n" is interpreted as newline in the code above. But if the string (i.e. $s) is in a file, it will be printed literally as "\n" - how do I get Perl to treat it as newline? /Why Tea -- To unsubscribe, e-mail: [EMAIL PROTECTED] For add