shivakrishna9 / pydsa

Python Data Structure and Algorithms

Home Page:http://pydsa.github.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

PyDSA

Build Status Join the chat at https://gitter.im/pydsa/pydsa Documentation Status

Mailing List: https://groups.google.com/forum/#!forum/pydsa

Python Data Structure and Algorithms Library (α-mode)

  1. Installation
  2. Usage
  3. Development Environment
  4. Contributing

Installation

To install PyDSA, simply run:

$ python setup.py install

Usage

In [1]: from pydsa import quick_sort

In [2]: a = [2, 10, 10, 2, 7, 7, 2, 5, 4, 10]

In [3]: quick_sort(a)
Out[3]: [2, 2, 2, 4, 5, 7, 7, 10, 10, 10]
In [1]: from pydsa import merge_sort

In [2]: b = [5, 1, 2, 3, 4, 3, 9, 7, 8, 5]

In [3]: merge_sort(b)
Out[3]: [1, 2, 3, 3, 4, 5, 5, 7, 8, 9]

Development Environment

The source code is managed with the Git version control system. To get the latest development version and access to the full repository, clone the repository from Github with:

$ git clone https://github.com/pydsa/pydsa.git

You should then install the development requirements:

pip install -r requirements.txt

To run tests:

$ py.test

Code Analysis

coala is used to lint and format code.

To analyze code using coala:

$ coala

There also other checks that you can run with coala:

$ coala pylint # checks the whole codebase against pylint.
$ coala invalidlinks # checks docs for invalid links.
$ coala imports # sort imports

Contributing

There are multiple ways you can contibute to Pydsa

  • Add missing documentation.
  • Add/improve efficiency of algorithms or Data structures.
  • Report bugs.
  • Request/Submit new algorithms.

Use github's Pull request/issues feature for all contributions.

About

Python Data Structure and Algorithms

http://pydsa.github.io

License:Other


Languages

Language:Python 100.0%