@ary = split //, $string; while ($i < @ary) { print @ary; unshift @ary, pop @ary; $i++; }