which loses characters if the string length is not an exact multiple of 10 (may not be a problem in this case?) One solution-
my @a = unpack('A10' x (length($string)/10) . 'A' . length($string)%10 +,$string);
--
my $chainsaw = 'Perl';
In reply to Re: Re: using unpack
by greenFox
in thread using unpack
by indapa
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |