Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Recursion Confusion

by live4tech (Sexton)
on Apr 27, 2013 at 06:12 UTC ( #1030922=perlquestion: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    sub factorial 
    {
    ...
       return 1 if $n == 0;
       return factorial($n-1) * $n;
    }
    
  2. or download this
    sub hanoi 
    {
    ...
          hanoi($n-1, $extra, $end, $start);
       }
    }
    
  3. or download this
    Move disk #1 from A to C.
    Move disk #2 from A to B.
    ...
    Move disk #1 from B to A.
    Move disk #2 from B to C.
    Move disk #1 from A to C.
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://1030922]
Approved by davido
Front-paged by kcott
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (6)
As of 2014-08-30 09:41 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (292 votes), past polls