Skip to main content
Donate to the Python Software Foundation or Purchase a PyCharm License to Benefit the PSF! Donate Now

Minimal implementation for constructing a suffix array

Project description

https://img.shields.io/pypi/v/tinysa.svg https://img.shields.io/travis/jun-harashima/tinysa.svg

tinysa is a minimal implementation for constructing a suffix array.

Quick Start

To install tinysa, run this command in your terminal:

$ pip install tinysa

Using tinysa, you can construct a suffix array as follows:

from tinysa.tinysa import TinySA

suffix_array = TinySA()
suffix_array.index('banana')

Then, you can find a suffix that begins with a substring as follows:

position = suffix_array.search('ana')
print(position)  # => 1

Project details


Download files

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

Filename, size & hash SHA256 hash help File type Python version Upload date
tinysa-0.2.2.tar.gz (8.2 kB) Copy SHA256 hash SHA256 Source None

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page