data-structures
5 tutorials tagged “data-structures”.
- Trees and Binary Search Trees in JavaA binary search tree keeps smaller keys on the left and larger keys on the right, giving fast search. Build insert, search, traversals and height in Java.
- Hashing and Hash Tables in JavaA hash table stores key-value pairs in buckets chosen by the key's hash code, giving O(1) lookups on average. Build one with chaining and resizing from scratch.
- Heaps in JavaA heap is a tree stored in an array where every parent is smaller than its children, so the minimum is on top. Build add and poll, then use PriorityQueue.
- Linked List Implementation in JavaBuild a singly linked list in Java from scratch: nodes, head, adding, removing, searching and reversing, then compare it with LinkedList and ArrayList.
- Stack and Queue Implementations in JavaBuild a stack (last in, first out) and a queue (first in, first out) from scratch in Java with arrays, then use ArrayDeque. Includes a bracket-checker example.