Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re^2: Recursive loops

by dsheroh (Parson)
on Dec 12, 2012 at 10:13 UTC ( #1008477=note: print w/ replies, xml ) Need Help??


in reply to Re: Recursive loops
in thread Recursive loops

In that case, you don't even need a queue. To restate your description of the process:

While subA detects faults, use subB to correct them.
Translating this to Perl is trivial:
while (subA(@array)) { subB(@array); }
or
while (my @faults = subA(@array)) { subB(\@array, \@faults); }
if subB needs to know what the list of faults was.


Comment on Re^2: Recursive loops
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1008477]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (8)
As of 2015-07-30 11:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (271 votes), past polls