Giter Site home page Giter Site logo

avltree's Introduction

avltree

An AVL tree implementation for C++!

An AVL tree is a self-balancing binary tree structure. It can be the basis of many types of data structures. For example, a red-black tree-- which is a similar data structure to an AVL tree-- is the basis for many common C++ data structures, such as mappings and sets.

This library attempts to provide a basic, customizable AVL tree for the implementation of other data structures which call for a self-balancing tree, such as an interval tree.

Requirements

The only requirement is the C++17 standard. Other than that it should be fine.

Documentation

There are two ways to view the documentation. The most recent version of the documentation is hosted on my github.io page. Alternatively, you can revert to a specific version tag within the repository and view the documentation stored in the doc folder. Currently, the only version is 1.0, but this may change in the future if bugs are found or if additional features wish to be added.

Building

This library makes use of CMake for easy integration into other projects. If you'd rather not use CMake, however, the library is written in such a way that it is simply one header and can be dropped anywhere you like.

Integrating this library into your CMake project is easy. First, add the subdirectory of the library:

add_subdirectory(path/to/avltree)

Then, add the link target to your link libraries:

target_link_libraries(your_project INTERFACE libavltree)

Simply #include <avltree.hpp> in your project after that and you should be able to build your project with CMake.

Testing

This library has been tested with Visual Studio 2019 and gcc-g++ 8.3.0 If you find yourself wishing to contribute to the library, you can run a test build with CMake:

$ mkdir build
$ cd build
$ cmake ../ -DTEST_AVLTREE=ON
$ cmake --build ./
$ ctest ./

The last line can be replaced with ctest -C Debug ./ when building with Visual Studio.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.