Encode.pm で、nkf もどき

#!/usr/bin/perl

use strict;
use Encode qw(from_to);
use Encode::Guess;

my $s = do {local $/; <STDIN>};
my $enc = Encode::Guess::guess_encoding ( $s );
#from_to( $s, $ARGV[0], $ARGV[1] );
from_to( $s, $enc, $ARGV[0] );
print $s, "\n";