I was working on the silly anagram program and needed something like Python's itertools.combinations. While I was working on it[1], I saw each_permutation and the same comment that Ben Alpert mentioned, so I took a pass at it:
https://gist.github.com/tmmcguire/4741058 I'd like to say that I'm really liking the lifetime variables. Then, I saw Ben and Niko's thread from January[2]. This version seems to be somewhat faster than the one there. I'd appreciate any comments, and if anyone's interested, I'll try to figure out how to create a pull request. :-) [1] https://github.com/tmmcguire/rust-toys/blob/master/combinations.rs [2] https://mail.mozilla.org/pipermail/rust-dev/2013-January/002857.html -- Tommy M. McGuire mcgu...@crsr.net _______________________________________________ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev