An open API service indexing awesome lists of open source software.

https://github.com/yutao-li/libheap

heap and indexheap library
https://github.com/yutao-li/libheap

data-structures heap heapsort

Last synced: 5 months ago
JSON representation

heap and indexheap library

Awesome Lists containing this project

README

          

# libheap
here is an implementation of a general heap library, including trivial heap and indexed heap, which not only supports the usual push , pop, peek operations, but also heapification, key modification, key deletion and self-defined comparator.

Indexheap is a significant heap structure which stores and sorts (index,key) pairs according to their key, it is essential in efficient implementation of Dijkstra's algorithm, Prim's algorithm and other variants.

Meanwhile, it also includes implementation of [Disjoint set](https://en.wikipedia.org/wiki/Disjoint-set_data_structure).

## Acknowledgement
this library is coded by reference to [algs4](https://algs4.cs.princeton.edu/code/). Much appreciation!

## Documentation
to be completed

## Installation
method 1: pip install --user libheap
method 2: download this project, and run "python setup.py install"
method 3: install anaconda, and run "conda install -c a870070392 libheap"
only support python3