![]() |
|
Syntactic Confectionery Delight | |
PerlMonks |
String differs from printing to STDOUT and printing to fileby cboesch (Initiate) |
on Oct 23, 2019 at 10:18 UTC ( [id://11107879]=perlquestion: print w/replies, xml ) | Need Help?? |
cboesch has asked for the wisdom of the Perl Monks concerning the following question:
Hi, When I print a variable to STDOUT: printf "%s.\n", $var; I get: QeTEv2804. When I print the same varible to a file: open DEBUG, ">>debug.txt" or confess "Couldn't open file"; printf DEBUG "%s.\n", $var; close DEBUG; I get: QeTEv2804^@^@^@. What could be the reason for that? Thanks, Christian
Back to
Seekers of Perl Wisdom
|
|