Skip to main content

a library for lazy people who are too lazy to write their own sorting

Project description

a library for lazy people who are too lazy to write their own sorting

there are sorting:

  • 1 bubble sorting

import arSort

array = [0, 6, 8, 4]
sort = arSort.Sort(array)

print(sort.bubbleSort("<")) #bubble sorting from smaller to larger
print(sort.bubbleSort(">")) #bubble sorting of more to less

input:

[0, 4, 6, 8]
[8, 6, 4, 0]
  • 2 sorting by shaker

import arSort

array = [0, 6, 8, 4]
sort = arSort.Sort(array)

print(sort.shakerSort("<")) #sorting the shaker from smaller to larger
print(sort.shakerSort(">")) #sorting the shaker from bigger to smaller

input:

[0, 4, 6, 8]
[8, 6, 4, 0]
  • 3 sorting comb

import arSort

array = [0, 6, 8, 4]
sort = arSort.Sort(array)

print(sort.hairbrushSort("<")) #sorting with a comb from smaller to larger
print(sort.hairbrushSort(">")) #sorting with a comb from more to less

input:

[0, 4, 6, 8]
[8, 6, 4, 0]
  • 4 sorting by inserts

import arSort

array = [0, 6, 8, 4]
sort = arSort.Sort(array)

print(sort.insertsSort("<")) #sorting by inserts from smaller to larger
print(sort.insertsSort(">")) #sorting by inserts from larger to smaller

input:

[0, 4, 6, 8]
[8, 6, 4, 0]
  • 5 sorting dwarves

import arSort

array = [0, 6, 8, 4]
sort = arSort.Sort(array)

print(sort.dwarvesSort("<")) #sorting dwarves from smaller to larger
print(sort.dwarvesSort(">")) #sorting dwarves from bigger to smaller

input:

[0, 4, 6, 8]
[8, 6, 4, 0]
  • 6 sorting the bongo clown (insane)

import arSort

array = [0, 6, 8, 4]
sort = arSort.Sort(array)

#we strongly advise against doing this, 
#because the worst indicator of the time of this sorting is infinity of seconds.
print(sort.bogoSort("<")) #sorting the bongo clown from smaller to larger
print(sort.bogoSort(">")) #sorting the bongo clown from bigger to smaller

input:

[0, 4, 6, 8]
[8, 6, 4, 0]

Project details


Release history Release notifications | RSS feed

This version

0.1

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

arSort-0.1.tar.gz (2.4 kB view hashes)

Uploaded Source

Built Distribution

arSort-0.1-py3-none-any.whl (2.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page