On 11/29/06, Martin DeMello < martindemello%40gmail.com">martindemello
gmail.com> wrote:
> I want to take a list and return the list of lists gained by removing
> each of its elements in turn, so that e.g. [1;2;3;4] => [2;3;4];
> [1;3;4];[1;2;4];[1;2;3]. How do I do this neatly and efficiently? Is
> there a better data structure than a list over which to do this? (The
> only other operation I need is linear iteration).
Okay, should've searched a little longer first!
http://www.lri.fr/~filliatr/ftp/ocaml/misc/anagram.ml.html is solving
pretty much the same problem I am, and in pretty much the same way, so
I'll just steal his multiset implementation 
martin
.