[Haskell-cafe] Dynamic Programming with Data.Vector

Roman Leshchinskiy rl at cse.unsw.edu.au
Mon Sep 17 15:07:41 CEST 2012


Myles C. Maxfield wrote:
>
> Overall, I'm looking for a function, similar to Data.Vector's 'generate'
> function, but instead of the generation function taking the destination
> index, I'd like it to take the elements that have previously been
> constructed. Is there such a function? If there isn't one, is this kind of
> function feasible to write? If such a function doesn't exist and is
> feasible to write, I'd be happy to try to write and contribute it.

Indeed there is, it's called constructN (or constructrN if you want to
construct it right to left).

Roman






More information about the Haskell-Cafe mailing list