Uses twice as much space, but could save time if moving characters around is expensive.use strict; my $string = shift @ARGV || 'space'; my $length = length $string; $string .= $string; for my $start (0 .. $length-1) { print substr($string, $start, $length), "\n"; }
In reply to Re: PUZZLED
by redcloud
in thread PUZZLED
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |