<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Sun, Feb 22, 2015 at 3:04 PM, Jeremy <span dir="ltr"><<a href="mailto:voldermort@hotmail.com" target="_blank">voldermort@hotmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Compared to the Nim code<br>
[<a href="https://github.com/logicchains/LPATHBench/blob/master/nim.nim" target="_blank">https://github.com/logicchains/LPATHBench/blob/master/nim.nim</a>] for a<br>
longest path algorithm, Haskell<br>
[<a href="https://github.com/logicchains/LPATHBench/blob/master/hs.hs" target="_blank">https://github.com/logicchains/LPATHBench/blob/master/hs.hs</a>] looks<br>
horrendously verbose and ugly, even if you ignore the pragmas and imports.<br>
<br>
Is this idiomatic Haskell style? Could it be clearer, but has to be written<br>
that way for performance - although it still takes 3.7x as long as the Nim<br>
version [<a href="https://github.com/logicchains/LPATHBench/blob/master/writeup.md" target="_blank">https://github.com/logicchains/LPATHBench/blob/master/writeup.md</a>]?<br>
<br></blockquote></div>A clearer version<br><a href="http://lpaste.net/120981">http://lpaste.net/120981</a><br></div><div class="gmail_extra">though this is 2x-3x slower than the Haskell version above.<br><br></div><div class="gmail_extra">Regards,<br></div><div class="gmail_extra">Jyotirmoy Bhattacharya<br></div><div class="gmail_extra"><a href="http://www.jyotirmoy.net">http://www.jyotirmoy.net</a><br></div></div>