[Haskell-cafe] Why is this code slow?

Jakub Arnold darthdeus at gmail.com
Tue Apr 29 19:15:18 UTC 2014


Hey guys,  

in my stumbling over Reddit I happened to find the following comment http://www.reddit.com/r/programming/comments/248abo/range_comprehensions_c/ch56g7b, where the poster shows a simple algorithm which is really slow when implemented in Haskell, compared to a C++ counterpart which does it the same way.

I’ve tried to figure this out, but my profiling skills don’t seem to be good enough for this. I’m not sure if this is somehow a limitation of list comprehensions, or if something else is wrong.

--  
Jakub

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20140429/ea812454/attachment.html>


More information about the Haskell-Cafe mailing list