Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re^2: Tail recursion using goto ⊂ (was: Re^3: Trinary Operator Semantics)

by Joost (Canon)
on May 27, 2005 at 17:21 UTC ( [id://461165]=note: print w/replies, xml ) Need Help??


in reply to Re: Tail recursion using goto ⊂ (was: Re^3: Trinary Operator Semantics)
in thread Trinary Operator Semantics

Wierd, though the tail version gets relatively more efficient if you increase the recursion level:
cmpthese( -10, { "normal" => sub { normal(500000) }, "tail" => sub { tail(500000) }, "faster" => sub { faster(500000) }, } );
s/iter normal tail faster normal 2.26 -- -22% -40% tail 1.77 28% -- -23% faster 1.36 66% 30% --

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others surveying the Monastery: (5)
As of 2024-04-23 09:20 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found