http://www.perlmonks.org?node_id=1034866


in reply to question regarding "v" flag of printf

Perl interprets each character in the string as its index in your character set. (In ASCII, character 49 is "1").

To split a string of digits, use:

my @digits = split //, '123';

For your second case, there are a few ways to do it, but unpack is a popular method:

my @nums = unpack '(A3)*', '100200300';

Note that both of these solutions don't actually care whether the strings contain digits or other characters like letters; if that matters to you, be sure to validate your input.