in reply to printing \n to a file
Just a data point here: Under WinNT 4.0 with Perl 5.6.0
(ActiveState's build 618), "\n" produces two
bytes (hex 0d 0a) in an output text file. Every DOS or Win32
build of Perl I've used has had this behaviour as I recall.