Dotfiles, utilities, and other apparatus.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

14 lines
341 B

#!/usr/bin/env perl
use warnings;
use strict;
use Encode;
use 5.10.0;
while (<>) {
say "length of raw input: " . length $_;
my $decoded = decode('UTF-8', $_);
say "length of decoded input: " . length $decoded;
say "encoded() on decoded input: " . encode('UTF-8', $decoded);
say "encode() on raw input: " . encode('UTF-8', $_);
}