On 2012-03-12 19:39, Kronheim, David (Contr) wrote:

 print "$line/n" ;

I think you meant:

  print "$line\n";


I prefer to write that as:

  print $line, "\n";

(which IIRC gets compiled to exactly the same opcodes)


I sometimes write it as

  print $line, $/;


Often I have a 'local $\ = "\n";' in scope,
which makes each print append a newline automatically.

--
Ruud

--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to