How to use
pip install shitsort
example usage:
import shitsort
myarray = [1, 5, 12, 6, 6, 11]
print(shitsort.bogosort(myarray))
print(shitsort.multibogosort(myarray, 4)) # uses 4 processes
print(shitsort.bozosort(myarray))
print(shitsort.slowsort(myarray))
print(shitsort.permutationsort(myarray))
print(shitsort.multipermutationsort(myarray, 4)) # uses 4 processes
>>> [1, 5, 6, 6, 11, 12]
>>> [1, 5, 6, 6, 11, 12]
>>> [1, 5, 6, 6, 11, 12]
>>> [1, 5, 6, 6, 11, 12]
>>> [1, 5, 6, 6, 11, 12]
>>> [1, 5, 6, 6, 11, 12]
functions:
bogosort(array)
returns a new sorted array of array using the bogosort algorithm without modifying the passed in array. (pseudocode)
multibogosort(array, numthreads)
returns a new sorted array of array using the bogosort algorithm without modifying the passed in array, but on multiple processes simultaneously. The number of processes can be specified with numthreads. Causes absurd CPU usage.
bozosort(array)
returns a new sorted array using the bozosort algorithm, without modifying the passed in array. (paper includes pseudocode somewhere)
slowsort(array)
returns a new sorted array using the slowsort algorithm, without modifying the passed in array. (pseudocode)
permutationsort(array)
returns a new sorted array by creating every permutation of the passed in array and looking through them. Uses absurd amounts of memory.
multipermutationsort(array, numthreads)
returns a new sorted array by creating every permutation of the passed in array and looks through it on numthreads processes. Uses absurd amounts of memory and CPU.
contributors: sh6heer, jas-dzied
Licensed under GPL GNUv3
Release files for shitsort 1.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| shitsort-1.2.0.tar.gz | 15.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| shitsort-1.2.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 32.5 kB
Release files / shitsort-1.2.0.tar.gz
| Download URL | shitsort-1.2.0.tar.gz |
|---|---|
| Size | 15.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0ff5da9b875f3f7649910fdc06a963c4d9a625d3025ba5ffc8113423f27ce920
|
|
BLAKE2b-256 checksum How to use checksums |
4e86911e26b0445e38961e1e3bd731f01fb725a107e8bef311882aad1e07bdb1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.0 CPython/3.9.12
|
Release files / shitsort-1.2.0-py3-none-any.whl
| Download URL | shitsort-1.2.0-py3-none-any.whl |
|---|---|
| Size | 17.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
613bfa0463013a012d1572803903a226bbea55f00f5b77113eff8e3b99c14133
|
|
BLAKE2b-256 checksum How to use checksums |
135620daca8443f4b21b5c290df37ec5309a2e64e26bb6ab12303f978fc9ad20
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.0 CPython/3.9.12
|