Search and Sort Modules
Different Search and Sort algorithms are implemented.
For now the functionality is really basic but it should evolve to a collection of several methods for searching elements and / or sorting sequences.
HowTo:
Available Sorting algorithms:
- Bubble Sort
- Quick Sort
- Shell Sort
Available Searching algorithms:
(returns index or False if element not found)
- Binary Search
- Hashmap
- Linear Search
Extra features:
Creating a random array.
- first parameter: length of array
- second parameter: range of numbers
Be aware that a tuple is returned, containing the array and a random chosen number of this array.
from SeaSor import SeaSor
SeaSor().get_int_array(length, range)
1.1) also available for ascii array:
from SeaSor import SeaSor
SeaSor().get_ascii_array(length, charset)
- Remove duplicates
from SeaSor import Search
# For example you want to remove duplicates
# before searching the index:
Search().rm_dupls([1,1,2,3])
# Output: [1,2,3]
- Write to (and/or Read) file
Following
How to import
- find index number of a element in a list (here the binary search method is applied)
from SeaSor import SeaSor
get_index = SeaSor.Search().bin_index(array, target)
Create an instance
Example:
from SeaSor import Sort
x = Sort
# Possible to set parameters for the object
# Also possible: Sort().quick([2,3,1])
# Or: Sort([2,3,1]).quick()
x.array = [2,3,1]
x.quick(x)
# Output: [1,2,3]
Available classes
from SeaSor import SeaSor
from SeaSor import Sort
from SeaSor import Search
from SeaSor import WriteRead
For more informations and instructions visit:
Metadata
Release files for SeaSor 0.1.3.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| SeaSor-0.1.3.5.tar.gz | 4.2 kB | Without provenance | Details for SeaSor-0.1.3.5.tar.gz |
Release files / SeaSor-0.1.3.5.tar.gz
| Download URL | SeaSor-0.1.3.5.tar.gz |
|---|---|
| Size | 4.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2664c0b52673e5b96c9967cf0ef13580c7ac0d7083961301c233182b38932d3f
|
|
BLAKE2b-256 checksum How to use checksums |
b36ed7bcb7c0c2e2cc5e1e319b6162a9eef0e9fa1c0410921566c1969592608b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3.post20200330 requests-toolbelt/0.9.1 tqdm/4.44.1 CPython/3.7.7
|
Security for SeaSor 0.1.3.5
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.