https://github.com/xiaobogaga/data-structure
another java collection library
https://github.com/xiaobogaga/data-structure
collection data-structures java
Last synced: 2 months ago
JSON representation
another java collection library
- Host: GitHub
- URL: https://github.com/xiaobogaga/data-structure
- Owner: xiaobogaga
- License: mit
- Created: 2018-07-25T06:47:05.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-02-17T05:58:40.000Z (about 7 years ago)
- Last Synced: 2023-12-20T21:55:08.970Z (over 2 years ago)
- Topics: collection, data-structures, java
- Language: Java
- Homepage:
- Size: 478 KB
- Stars: 1
- Watchers: 0
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
java collection implementations for the data structures talked about in
the book **DATA STRUCTURES AND ALGORITHM ANALYSIS IN JAVA, THIRD EDITION**
[](https://travis-ci.org/xiaobogaga/data-structure)
[](https://www.javadoc.io/doc/io.github.xiaobogaga/datastructure)
[](https://search.maven.org/search?q=g:%22io.github.xiaobogaga%22%20AND%20a:%22datastructure%22)
Yep, this can be seen as another collection library like java collection
framework, but it provides other data structure implementations like
Splay Tree, AVL Tree, Red-black Tree etc. it includes:
* List:
**LinkedList**
**ArrayList**
**Stack**
**Queue**
* Tree:
**Basic Tree**
**Binary Search Tree**
**AVL tree**
**Splay Tree**
**Red-black tree**
**TreeMap**
**TreeSet**
**HashMap based on Red-black Tree**
**BTree**
**SkipList**
**Treap**
**Tries**
* Heap:
**Basic Min-Heap**
**Leftist Heap**
**Skew Heap**
**Binomial Heap**
**DoubleEndedHeap**
* Hash:
**Basic Hash Table by seperate chain**
**Hash Table by linear probing, quadratic probing**
**Perfect Hash Table**
**Cuckoo Hash Table**
**Hopscotch Hash Table**
**Extensible Hash Table**
* BitMap:
**BitMap**
* External memory data structure(they can hold long key and long value):
**HashTable**
**BPlusTree**
# Features
Most of class provides few but really necessary functions, the benefit about this is that it
can make code clean, more readable and more extensible. I also make
data structures separate, For example, hashmap could be built on
red-black tree array and this is what java hashmap does, but it turns
out java hash map implementation is very very complicated, if you go
into java hash map source code since jdk 1.8, then you can get 2390 line
codes, and my hash map implementation only has 160 line. This is
another reason I built this.
# Documentations
For a detailed api documentation, please go to api docs.
# Examples
* [List](https://github.com/xiaobogaga/data-structure/tree/master/src/main/java/io/github/xiaobogaga/list)
* [Tree](https://github.com/xiaobogaga/data-structure/tree/master/src/main/java/io/github/xiaobogaga/tree)
* [Heap](https://github.com/xiaobogaga/data-structure/tree/master/src/main/java/io/github/xiaobogaga/heap)
* [Hash](https://github.com/xiaobogaga/data-structure/tree/master/src/main/java/io/github/xiaobogaga/hash)
* [BitMap](https://github.com/xiaobogaga/data-structure/tree/master/src/main/java/io/github/xiaobogaga/bitmap)
* [External](https://github.com/xiaobogaga/data-structure/tree/master/src/main/java/io/github/xiaobogaga/external)