Yes, you are absolutely right that not every recursive solution will use tail calls (the wikipedia…
m1el —
There are algorithms that cannot be optimized "away" using tail call elimination. For example, tre…
I highly recommend anything about compiling Scheme to C, "Cheney on the MTA" being a prime example…
Regarding recursion and worry about stack frames. Modern compilers can optimize this away and use …
New results: Recursive (Forwards): 198543 cycles Recursive (Backwards): 202639 cycles Non-recursiv…
Whoop, thought I sanitized all that :P PushAllArrayIndirected (what a mouthful) is just this: And…
and are the same thing? What does look like?
Ah, yeah, I thought of that but wasn't sure it would make much difference. I guess since I'm only …
Is it possible that you're visiting the children in a different order in the non-recursive version…
As with many things, 3dmasons, it's hard to say whether something is "bad" out of context. In a "s…
My std:: container comparison was popular on twitter, so I figured I better replicate the usage co…
More code gen from the ZeroMQ / nanomsg guy: I imagine a DNA reader implementation for C wouldn't…
I remember you mentioned Steven Pinker's "" in the first part of your . I am glad that more peopl…
Okay, so I did some initial tests and here's what I've got. The actual cycle count isn't too relev…
When calling a function recursively, take also into account that the whole state of the function (…
Looks like his two major arguments against it are:Repeated function calls result in overhead, pre…
from author V. Anton Spraul (pages 24-27) for some arguments to think about.
Paul —
Awesome, thanks ChronalDragon!
I'm writing some code that seems like it would be simpler to express using a recursive method (it'…
If your file structure means that a file will be included twice, the compiler will have no qualms …
Paul —
Very interesting, Casey. Thank you greatly for your replies. In your opinion and from experience, …
Expanding on gazto's comments, those interested in the topic should check out Steven Pinker's most…
I usually set up a dummy project, then set the "run" settings to create a custom run config to poi…
Perhaps this will work from the command line: For more info, check .
Hello, I'm trying to use Qt Creator for debugging on Linux (for a side project). As for now I open…
To reduce the length of lines, I sometimes like to format function calls like this: (I suppose th…
I agree. However, one constructive criticism I insist on the didactic side is that it seems to suf…
The problem with const is that the C++ spec is busted, so there's no real way for the compiler to …
Paul —
All good, insanoflex, I appreciate the help you've given, and I understand that I should only incl…
Yes - on my dev machine at work I only use Etymotic ER4p's and you can hear every single bug on th…