[Haskell] dynamic arrays

minh thu noteed at gmail.com
Fri Mar 17 13:45:39 EST 2006

2006/3/17, Bulat Ziganshin <bulat.ziganshin at gmail.com>:
> Hello Jared,
> Thursday, March 16, 2006, 11:35:24 PM, you wrote:
> JU> General question to the list:
> JU> (Q)  Are there any data structures in Haskell similar to C++/STL
> JU> vectors or C# generic Lists (i.e. strongly typed ArrayLists, e.g.
> JU> List<int>)? These data structures grow automatically as you add
> JU> elements to them (but in large chunks, not one node at a time). This
> JU> data structure (if it exists in Haskell) would run inside a monad (ST
> JU> and/or IO) and it would automaticly resize when needed, but would be
> JU> more or less like a mutable array except you can add new elements to
> JU> the end of it without reallocating an entire array of n+1 elements...
> i tried to implement this today [...mail cut here ...]

when you say you try to implement it, how do you do it ? c -> ffi -> haskell ?

minh thu

More information about the Haskell mailing list