Learn R Programming

CEGO (version 2.4.3)

solutionFunctionGeneratorPermutation: Permutation Generator Function

Description

Returns a function that generates random permutations of length N. Can be used to generate individual solutions for permutation problems, e.g., Travelling Salesperson Problem

Usage

solutionFunctionGeneratorPermutation(N)

Value

returns a function, without any arguments

Arguments

N

length of the permutations returned

Examples

Run this code
fun <- solutionFunctionGeneratorPermutation(10)
fun()
fun()
fun()

Run the code above in your browser using DataLab