The hottest sorting algorithm around!
Project description
Volcano Sort
The hottest sorting algorithm around!
Disclaimer
This algorithm runs in O(n2). Please don't use this.
Motivation
Our professor mentioned volcanoes when discussing sorting algorithms. I realized there wasn't a "Volcano Sort". There shouldn't be, but now there is.
Methodology
This algorithm first constructs a volcano from the input. Then, the volcano "erupts" and places the numbers in sorted order.
What does this mean?
Given the following input: [4,8,2,2,1,3,0], Volcano Sort will construct a volcano: [1,2,4,8,3,2,0]. It looks like this:
The volcano will erupt and place numbers in increasing order.
Output: [0,1,2,2,3,4,8]
Installation
pip install VolcanoSort
Usage
from VolcanoSort import volcano
arr = [4, 5, 8, 1, 2, 3, 7, 6, 9]
arr = volcano.sort(arr)
print(arr)
[1, 2, 3, 4, 5, 6, 7, 8, 9]
Future Development
None!
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file VolcanoSort-1.0.4.tar.gz.
File metadata
- Download URL: VolcanoSort-1.0.4.tar.gz
- Upload date:
- Size: 3.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.0 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
739ce7f9158ad896bf270853aceec2278df8cdd24ed5e401c7377d3e0613178f
|
|
| MD5 |
8a3ea1ecc0a92952df291a449cbc9a19
|
|
| BLAKE2b-256 |
4feaf1da910480c8de399e1a07591c9a234d062e3bb7440f1ae89cb267d9712b
|
File details
Details for the file VolcanoSort-1.0.4-py3-none-any.whl.
File metadata
- Download URL: VolcanoSort-1.0.4-py3-none-any.whl
- Upload date:
- Size: 3.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.0 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
df09fce48c915446c3caff0d495afa3fc226a091cbde09449af03b00d1d55283
|
|
| MD5 |
ad87c0c4675641f5948df9a3713e961a
|
|
| BLAKE2b-256 |
c39042dab537e59e7b33e7dc042ff73f410214402b7243fe734ad764161426b8
|