crypto-classical-0.3.0: An educational tool for studying classical cryptography schemes.

Copyright(c) Colin Woodbury 2015 - 2020
LicenseBSD3
MaintainerColin Woodbury <colin@fosskers.ca>
Safe HaskellNone
LanguageHaskell2010

Crypto.Classical.Shuffle

Contents

Description

Code borrowed from `random-shuffle` and modified to match crypto-random data types.

Synopsis

List Scrambling

shuffle :: CPRG g => g -> [a] -> Integer -> [a] Source #

Given a sequence (e1,...en) to shuffle, its length, and a random generator, compute the corresponding permutation of the input sequence.