http://www.perlmonks.org?node_id=9470

Simplicus has asked for the wisdom of the Perl Monks concerning the following question:

I am out on the road, and only have a laptop (w/out Perl) so I can't test this out....
Can I erase the contents of a file this way (I don't want to unlink the file, I just want to "clean it out.":
... s/./\004/; ...
Where \004 is ^D?
Simplicus