QUOTE(betaplan @ Mar 30 2013, 17:41)

You're in an imperative language. Just optimize the tail recursion out yourself.
Never found a way of doing it, although my java knowledge is crap so maybe there's a way and I simply did not find it yet. How would you suggesst doing the tail recursion optimization by hand? i.e. do you maybe happen to know how can I modify the function call stack, in java, to throw away the unneeded function retunrs and return controll directly to the beginning of the recursion (instead of accumulating the unneeded function retuns, and the unneded stack of each function, in memory)?