https://github.com/ferhatgec/gechsort
Gechsort loves permutations.
https://github.com/ferhatgec/gechsort
lib python python3 script sort sorting-algorithms
Last synced: about 2 months ago
JSON representation
Gechsort loves permutations.
- Host: GitHub
- URL: https://github.com/ferhatgec/gechsort
- Owner: ferhatgec
- License: mit
- Created: 2021-07-03T18:47:13.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2021-07-03T18:59:45.000Z (almost 5 years ago)
- Last Synced: 2025-05-31T03:29:49.412Z (about 1 year ago)
- Topics: lib, python, python3, script, sort, sorting-algorithms
- Language: Python
- Homepage:
- Size: 1.95 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Gechsort
## Gechsort loves permutations.
### Algorithm (pseudo):
```rust
f(data: list)
(min, mid, max, sort) := min_of(data), mid_of(data), max_of(data), sort(data)
(permutations, generated) := p(elements), empty([])
for per arr in permutations :=
if first_of(arr) == min and last_of(arr) == max and mid_of(arr) == mid :=
append(generated, arr)
=:
=:
for per arr in generated :=
if arr == sort :=
return arr
=:
=:
```
### Gechsort licensed under the terms of MIT License.