in reply to A regex question...
Of course, you could inline the unpack in to the printf, if you so chose. The bonus (or maybe not, depending on your situation) is that this works with letters and numbers.my $string = "012345678901234567890123456789"; my @array = unpack("A5" x 6, $string); printf("%s-%s-%s<br>%s-%s-%s\n", @array);
thor
|
|---|