{"id":18463040,"url":"https://github.com/shawnjeffersonwang/data-structures","last_synced_at":"2026-01-30T17:33:12.316Z","repository":{"id":213714880,"uuid":"734395083","full_name":"ShawnJeffersonWang/data-structures","owner":"ShawnJeffersonWang","description":"This repository is a comprehensive collection of data structures and algorithms implemented in Java. It aims to provide clear and efficient implementations for educational purposes and practical use. The data structures are organized by difficulty level, making it easy to find and understand each concept.","archived":false,"fork":false,"pushed_at":"2024-08-05T08:58:56.000Z","size":176,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-06T11:05:15.971Z","etag":null,"topics":["algorithms","datastructures","datastructures-algorithms","java"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ShawnJeffersonWang.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-12-21T15:15:27.000Z","updated_at":"2024-10-06T15:15:32.000Z","dependencies_parsed_at":"2023-12-22T16:12:54.339Z","dependency_job_id":"cd9fc2f8-90a0-4ec2-9813-3a0d5dc8b12b","html_url":"https://github.com/ShawnJeffersonWang/data-structures","commit_stats":null,"previous_names":["shawnjeffersonwang/algo","shawnjeffersonwang/datastructures","shawnjeffersonwang/data-structures"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ShawnJeffersonWang/data-structures","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ShawnJeffersonWang%2Fdata-structures","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ShawnJeffersonWang%2Fdata-structures/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ShawnJeffersonWang%2Fdata-structures/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ShawnJeffersonWang%2Fdata-structures/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ShawnJeffersonWang","download_url":"https://codeload.github.com/ShawnJeffersonWang/data-structures/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ShawnJeffersonWang%2Fdata-structures/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28916111,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-30T16:37:38.804Z","status":"ssl_error","status_checked_at":"2026-01-30T16:37:37.878Z","response_time":66,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["algorithms","datastructures","datastructures-algorithms","java"],"created_at":"2024-11-06T09:05:41.172Z","updated_at":"2026-01-30T17:33:12.286Z","avatar_url":"https://github.com/ShawnJeffersonWang.png","language":"Java","readme":"# Java Data Structures and Algorithms\n\nThis repository contains implementations of various data structures and algorithms in Java. The implementations cover\nbasic, intermediate, and advanced topics to help you understand and utilize these concepts in your projects.\n\n## Table of Contents\n\n1. [Basic Data Structures](#basic-data-structures)\n    - [ArrayList](#arraylist)\n    - [LinkedList](#linkedlist)\n    - [Queue](#queue)\n    - [Stack](#stack)\n    - [Binary Search Tree (BST)](#binary-search-tree-bst)\n    - [Binary Tree](#binary-tree)\n\n2. [Intermediate Data Structures](#intermediate-data-structures)\n    - [Heap](#heap)\n    - [PriorityQueue](#priorityqueue)\n    - [BlockingQueue](#blockingqueue)\n    - [Deque (Double-Ended Queue)](#deque-double-ended-queue)\n\n3. [Advanced Data Structures](#advanced-data-structures)\n    - [HashMap](#hashmap)\n    - [Disjoint Set (Union-Find)](#disjoint-set-union-find)\n    - [Red-Black Tree](#red-black-tree)\n    - [AVL Tree](#avl-tree)\n    - [B-Tree](#b-tree)\n    - [Graph](#graph)\n\n4. [Algorithms](#algorithms)\n    - [Depth-First Search (DFS)](#depth-first-search-dfs)\n    - [Breadth-First Search (BFS)](#breadth-first-search-bfs)\n    - [Dijkstra's Algorithm](#dijkstras-algorithm)\n    - [Kruskal's Algorithm](#kruskals-algorithm)\n\n## Basic Data Structures\n\n### ArrayList\n\nAn implementation of a resizable array, similar to the built-in `ArrayList` in Java.\n\n### LinkedList\n\nA doubly linked list implementation, providing efficient insertion and deletion operations.\n\n### Queue\n\nA first-in, first-out (FIFO) data structure implementation.\n\n### Stack\n\nA last-in, first-out (LIFO) data structure implementation.\n\n### Binary Search Tree (BST)\n\nA tree data structure in which each node has at most two children, with the left child having a smaller value and the\nright child having a larger value.\n\n### Binary Tree\n\nA tree data structure where each node has at most two children.\n\n## Intermediate Data Structures\n\n### Heap\n\nA complete binary tree which satisfies the heap property, useful for priority queue implementations.\n\n### PriorityQueue\n\nAn advanced queue that allows for the retrieval of elements according to their priority.\n\n### BlockingQueue\n\nA thread-safe queue that supports operations that wait for the queue to become non-empty when retrieving an element and\nwait for space to become available in the queue when storing an element.\n\n### Deque (Double-Ended Queue)\n\nA queue that supports insertion and removal of elements from both ends.\n\n## Advanced Data Structures\n\n### HashMap\n\nA data structure that implements a map interface using hashing for efficient key-value pair storage.\n\n### Disjoint Set (Union-Find)\n\nA data structure that keeps track of a partition of a set into disjoint (non-overlapping) subsets, useful for Kruskal's\nalgorithm and network connectivity.\n\n### Red-Black Tree\n\nA balanced binary search tree with additional properties to ensure the tree remains balanced during insertions and\ndeletions.\n\n### AVL Tree\n\nA self-balancing binary search tree where the difference between heights of left and right subtrees cannot be more than\none for all nodes.\n\n### B-Tree\n\nA self-balancing tree data structure that maintains sorted data and allows for efficient insertion, deletion, and search\noperations.\n\n### Graph\n\nA data structure consisting of nodes (vertices) and edges connecting pairs of nodes, useful for representing networks\nand relationships.\n\n## Algorithms\n\n### Depth-First Search (DFS)\n\nAn algorithm for traversing or searching tree or graph data structures, starting from the root and exploring as far as\npossible along each branch before backtracking.\n\n### Breadth-First Search (BFS)\n\nAn algorithm for traversing or searching tree or graph data structures, starting from the root and exploring all\nneighbor nodes at the present depth level before moving on to nodes at the next depth level.\n\n### Dijkstra's Algorithm\n\nAn algorithm for finding the shortest paths between nodes in a graph, which may represent, for example, road networks.\n\n### Kruskal's Algorithm\n\nAn algorithm for finding the minimum spanning tree of a graph, which finds a subset of the edges that connects all\nvertices together without any cycles and with the minimum possible total edge weight.\n\n## Contributing\n\nContributions are welcome! Please open an issue or submit a pull request with your improvements.\n\n## License\n\nThis project is licensed under the Apache License 2.0 - see the [LICENSE](LICENSE) file for details.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshawnjeffersonwang%2Fdata-structures","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshawnjeffersonwang%2Fdata-structures","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshawnjeffersonwang%2Fdata-structures/lists"}