Metadata-Version: 2.1
Name: random_permutation
Version: 0.1.12
Summary: A module for efficiently generating very large random permutations
Author: Gary William Flake
Author-email: gary@flake.org
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: cryptography

# Random Permutation

This module provides a class `RandomPermutation` that can be used to
generate a random permutation of a given length in O(1) time and space.

## Installation

To install the module, run:

```
pip install random_permutation
```

## Usage

To use the `RandomPermutation` class, import it from the `random_permutation` module:

```python
from random_permutation import RandomPermutation

n = 2**20
p = RandomPermutation(n)
for x in p:
  print(x)
# or
for i in range(n):
  print(p[i])
```

This will output the elements of the `RandomPermutation` object. You can
use the `seed` parameter to vary the permutations and the `num_ciphers`
parameter to control the number of ciphers used.

## Testing

To run the unit tests for the `RandomPermutation` class, run:

```
python -m unittest tests.test_permutation
```

## License

This module is licensed under the MIT License.
