motzi has asked for the wisdom of the Perl Monks concerning the following question:
Here, depending on the length i remove or add more foreach loop. Well, i need for example a 15-length string generation, need to make 15 loops, its a bit hard work.@chartab = (0..9, a..z); foreach $first (@chartab) { foreach $second (@chartab) { foreach $third (@chartab) { print $first, $second, $third, ","; } } }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: loop in loop method evasion
by ikegami (Patriarch) on Dec 26, 2009 at 06:24 UTC | |
Re: loop in loop method evasion
by eye (Chaplain) on Dec 26, 2009 at 06:00 UTC | |
by ikegami (Patriarch) on Dec 26, 2009 at 06:56 UTC | |
by motzi (Sexton) on Dec 26, 2009 at 15:43 UTC | |
Re: loop in loop method evasion
by Anonymous Monk on Dec 26, 2009 at 05:07 UTC | |
by ikegami (Patriarch) on Dec 26, 2009 at 06:34 UTC | |
Re: loop in loop method evasion
by biohisham (Priest) on Dec 26, 2009 at 05:10 UTC | |
Re: loop in loop method evasion
by bobr (Monk) on Dec 26, 2009 at 09:17 UTC | |
Re: loop in loop method evasion
by bduggan (Pilgrim) on Dec 26, 2009 at 18:17 UTC |