Function: random_shuffle

Function: random_shuffle

since 0.3.7

Usage

 random_shuffle(some_list)

Randomly shuffle a list, putting the elements in a different order.

Since the result is random, calling the function twice will give a different answer.

Parameters

Parameter Type Description
input list List to shuffle.

Examples

 random_shuffle([1,2,3,4]) == [4,1,2,3]
 random_shuffle([1,2,3,4]) == [2,3,4,1]

See also

random_select Pick a single random element from a list.
random_select_many Pick multiple random elements from a list.