fork download
  1. #!/usr/bin/perl
  2. use List::Util 'shuffle';
  3.  
  4. @words = split /\s+/, <>;
  5. print join ' ', map { join '', shuffle split//, $_ } @words;
  6. print "\n" . join ' ', @words;
Success #stdin #stdout 0s 3764KB
stdin
abc
cba
stdout
acb
abc