c05mic / Genericn Arytree
Simple Generic N-ary Tree implementation in Java, with many utility methods.
Stars: ✭ 40
Programming Languages
java
68154 projects - #9 most used programming language
Projects that are alternatives of or similar to Genericn Arytree
Metric Parser
📜 AST-based advanced mathematical parser written by Typescript.
Stars: ✭ 26 (-35%)
Mutual labels: tree
Pie
🍕 Enjoy a slice! A utility library for dealing with slices and maps that focuses on type safety and performance.
Stars: ✭ 788 (+1870%)
Mutual labels: generics
React Native Pathjs Charts
Android and iOS charts based on react-native-svg and paths-js
Stars: ✭ 877 (+2092.5%)
Mutual labels: tree
Deepdiff
Deep Difference and search of any Python object/data.
Stars: ✭ 985 (+2362.5%)
Mutual labels: tree
Time
Type-safe time calculations in Kotlin, powered by generics.
Stars: ✭ 939 (+2247.5%)
Mutual labels: generics
Christmas Tree
ASCII christmas-tree with animations for 256 colored terminals
Stars: ✭ 23 (-42.5%)
Mutual labels: tree
Tree printer
A Java class for printing binary trees as ASCII text
Stars: ✭ 20 (-50%)
Mutual labels: tree
Vue.d3.tree
Vue component to display tree based on D3.js layout.
Stars: ✭ 726 (+1715%)
Mutual labels: tree
Goderive
Code Generation for Functional Programming, Concurrency and Generics in Golang
Stars: ✭ 848 (+2020%)
Mutual labels: generics
Cracking The Coding Interview
Solutions for Cracking the Coding Interview - 6th Edition
Stars: ✭ 35 (-12.5%)
Mutual labels: tree
Js Tree List
Convert list to tree, managing a tree and its nodes.
Stars: ✭ 30 (-25%)
Mutual labels: tree
Simple Generic N-ary Tree implementation in Java
Utility methods:
- To check if a node exists in the tree.
- To find the total number of nodes in the tree
- To find the total number of descendants of any node in the tree.
- To get all the paths from the root to all the leaves as a List.
- To get all longest path from the root to any leaf.
- To get the pre-order/post-order traversal path as a List.
Example Usage:
// Create a new Integer type node
Node<Integer> root = new Node<Integer>(1);
// Add a child
root.addChild(new Node<Integer>(2));
// Create a tree, providing the root node
Tree<Integer> tree = new Tree<Integer>(root);
// Get the pre-order traversal
List<Node<Integer>> preOrder = tree.getPreOrderTraversal();
Download:
Maven:
<dependency>
<groupId>com.c05mic.generictree</groupId>
<artifactId>GenericN-aryTree</artifactId>
<version>1.1.1</version>
</dependency>
Gradle:
repositories {
mavenCentral() // jcenter() works as well because it pulls from Maven Central
}
dependencies {
compile 'com.c05mic.generictree:GenericN-aryTree:1.1.1'
}
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].