[Haskell-beginners] Question on Lists
nathanmholden at gmail.com
Sun Apr 19 15:24:15 EDT 2009
I have been reading Chris Okasaki's PhD thesis on Purely Functional Data
Structures (www.cs.cmu.edu/~rwh/theses/*okasaki*.pdf) and it discusses his
idea of lazy lists (He uses Standard ML in the paper), and it raised some
questions for me.
To cut to the chase, my question is this:
Say I have list x of length n, and I have a single piece of data y. Does
x ++ [y]
take more cycles, or the same as if I'd said y:[x] (which would get it on
the wrong side?)
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Beginners