Showing posts with label tail recursion. Show all posts
Showing posts with label tail recursion. Show all posts

2018-04-10

To be fair with Haskell

Fairy Tales

In Java 8, functional style and efficiency I have shown how bad Haskell performs at the silly task I was using as test.

But there's a detail which makes the test unfair: the problem with the given code is that the factorial function I've written isn't tail recursive.