![]() |
|
"be consistent" | |
PerlMonks |
Fast string constructionby citromatik (Curate) |
on Apr 07, 2011 at 13:00 UTC ( #898040=perlquestion: print w/replies, xml ) | Need Help?? |
citromatik has asked for the wisdom of the Perl Monks concerning the following question: Hi all I am storing some data in a long string of "ints":
Since the $keys in the file are not sorted, I need to initialize substr with enough values (to avoid a "substr outside of string" error). Currently I am doing it like follows:
Is there a more efficient way (maybe in one go instead of looping) of doing this? Thanks in advance citromatik
Back to
Seekers of Perl Wisdom
|
|