Java generic Iterator implementation to generate permutations and combinations.
Uses the algorithm described here http://en.wikipedia.org/wiki/Steinhaus%E2%80%93Johnson%E2%80%93Trotter_algorithm#Even.27s_speedup and the clear description of that algorithm here: http://www.cut-the-knot.org/Curriculum/Combinatorics/JohnsonTrotter.shtml
Features
- Iterator going through all permutations of elements in a Collection
- Iterator going through all pair wise swaps required to generate all permutations
- Iterator generating all combinations of elements in a Collection
- All strongly typed by using generic type (Iterator<T>)
License
BSD LicenseFollow SwapPermutationsIterator
You Might Also Like
Our Free Plans just got better! | Auth0 by Okta
You asked, we delivered! Auth0 is excited to expand our Free and Paid plans to include more options so you can focus on building, deploying, and scaling applications without having to worry about your secuirty. Auth0 now, thank yourself later.
Rate This Project
Login To Rate This Project
User Reviews
Be the first to post a review of SwapPermutationsIterator!