Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

WHICH IS FASTER

Name: Anonymous 2008-07-04 8:27

(incf foo) or (+ 1 foo)

Name: Anonymous 2008-07-04 18:44

>>1,6
Those two mean exactly the same, but as incf is more readable, use that.

>>2
++i:
i = i + 1;
return i

i++:
tmp = i
i = i + 1
return tmp

>>9
foldl: Slow, sucks, etc.
foldl': Strict version of foldl, so it's faster, but it doesn't work on infinite lists.
folrd: Infinite list goodness.

Conclusion: foldl' for finite lists, foldr for infinite.

>>15
gcc for c, ghc for haskell...

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List