Skip to content

dos_permute

Dale Fugier edited this page Jul 1, 2026 · 1 revision

Returns all permutations of the elements in a list.

Syntax

(dos_permute list)

Parameters

list

A list of values to permute. The list may contain numbers, strings, or a combination of both.

Returns

A list containing all permutations of the supplied list if successful.

nil on error.

Example

Command: (dos_permute '(1 2 3))
((1 2 3) (1 3 2) (2 1 3) (2 3 1) (3 1 2) (3 2 1))

Clone this wiki locally