How can the code for permutations (appended) be modified to output only complete permutations. A complete permutation is a permutation of the order of distinct items in which no item appears in its original place.
Attaching a reference link https://rosettacode.org/wiki/Permutations/Derangements. A derangement is a permutation of the order of distinct items in which no item appears in its original place. For example, the only two derangements of the three items (0, 1, 2) are (1, 2, 0), and (2, 0, 1).
CROSS POSTED by me in Mr. Excel at https://www.mrexcel.com/board/thread.../#post-5610896.
Please Login or Register to view this content.
Bookmarks