http://www.perlmonks.org?node_id=77821


in reply to Re: (Golf) Per Mutations
in thread (Golf) Per Mutations

Perhaps you'll be able to knock off a few more chars, since the sub isn't supposed to print anything - it only needs to return the data structure specified in the problem description.

A brief reduction of this sub gives 79 chars though:

sub t{!@_&&print@r,"\n";for my$i(1..@_){push@r,$_[$i-1];t(@_[0..$i-2,$ +i..$#_]);pop@r}}
   MeowChow                                   
               s aamecha.s a..a\u$&owag.print