in reply to Re^2: Splitting up a string by lengths
in thread Splitting up a string by lengths

in reasonably recent perls, you can do stuff like this:
my @cc = unpack("(A4)4", "1234567890123456");
instead of the more verbose
my @cc = unpack("A4A4A4A4", "1234567890123456");
I've used it in the past with great success. Besides...it might improve your golf game. :)

thor

Feel the white light, the light within
Be your own disciple, fan the sparks of will
For all of us waiting, your kingdom will come

Replies are listed 'Best First'.
Re^4: Splitting up a string by lengths
by kwaping (Priest) on Jul 26, 2005 at 14:29 UTC
    Good additional info, thanks!