Help for this page

Select Code to Download


  1. or download this
    use utf8::all; # Comment out for Windows
    use Unicode::Collate;
    
    ...
    my @entries = $collator->sort(@list);
    print "$_\n" for (@entries);
    print "\tEnd sorted\n\n";
    
  2. or download this
    [...]
    use Config;
    use utf8::all if $Config{osname} eq 'Linux'; # perl adamantly ignores 
    +the condition
    [...]
    
  3. or download this
    use if $^O ne 'MSWin32', 'utf8::all';
    system('chcp 1252') if $^O eq 'MSWin32';