Generates an integer array of length k whose entries are selected randomly, without repetition, from the integers 0 through n-1 (inclusive).
Generated arrays represent permutations of n taken k at a time.
Preconditions:
k <= n
n > 0
If the preconditions are not met, an IllegalArgumentException is thrown.
@param n domain of the permutation
@param k size of the permutation
@return random k-permutation of n
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.