CreatingRhythms-0.0.27.0
Copyright(c) Eric Bailey 2025
LicenseMIT
Maintainereric@ericb.me
Stabilityexperimental
PortabilityPOSIX
Safe HaskellSafe-Inferred
LanguageGHC2021

Data.Rhythm.Permutations

Description

Strictly lexicographically larger permutations of a given list of numbers.

Synopsis

Documentation

permutations :: Integral a => [a] -> [[a]] Source #

Strictly lexicographically larger permutations of a given list of numbers.

>>> permutations [1,2,3]
[[1,2,3],[2,1,3],[3,2,1],[2,3,1],[3,1,2],[1,3,2]]
>>> permutations [3,1,2]
[[3,1,2],[3,2,1]]