in reply to Re: wierd output
in thread wierd output

FWIW, a smarter way would be

cheat( "/home/cheatsheets/$prefix.txt" , \*STDOUT ); sub cheat { my( $cheatfile, $outhandle ) = @_; open my($info), '<', $cheatfile or die "Can't open( $cheatfile ): +$!"; while(<$info>){ print $outhandle $_; } close $info; }

But if you're going to write that you might as well use File::Copy::copy :)

use File::Copy qw' copy '; copy( "/home/cheatsheets/$prefix.txt" , \*STDOUT );

This assuming you're only copy-ing verbatim