There's also a simple regex solution to that ;-)
#!/usr/bin/perl -w use strict; print 'What string would you like to twiddle? '; chomp(my $twiddle = <STDIN>); $twiddle =~ /^(.+?)(?{print $1,"\n";})$/; # up chop($twiddle); $twiddle =~ /^(.+)(?{print $1,"\n";})^/; # down
-- Hofmator
In reply to Re: Twiddle
by Hofmator
in thread Twiddle
by Siggy
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |