This repository is a structured collection of Java programs covering the complete spectrum of Data Structures and Algorithms (DSA). It serves as a go-to reference and learning tool for beginners and intermediate learners preparing for technical interviews, coding contests, or academic assignments.
The project is organized into topic-wise directories, each containing Java source files demonstrating concepts, patterns, and problems.
.
├── App.java / App.class # Entry point or test class
├── index.js # Optional front-end or visualization aid
├── Arrays/ # Array operations & basics
├── Bits/ # Bit manipulation techniques
├── DynamicProgramming/ # Classical DP problems (LIS, coin change, etc.)
├── Graph/ # Directed, Undirected Graphs, Union-Find
├── Greedy/ # Greedy approach and examples
├── HashMap/ # HashMap use cases and methods
├── Heap/ # Heap structure and its methods
├── LinkedList/ # Linked List operations and patterns
├── Matrix/ # 2D matrix problems and algorithms
├── Queue/ # Queue operations and types
├── Recursion/ # Recursive algorithms and backtracking
├── SearchingAndSorting/ # Classic search/sort techniques
├── Stack/ # Stack implementation and usage
├── Tree/ # BST, AVL, Binary & Generic Trees
└── Trie/ # Prefix tree structure and methods
- Language: Java
- Tools: Any Java IDE (IntelliJ IDEA, VSCode, Eclipse)
- Compilation:
javac
,java
CLI or IDE run tools
-
Clone this repository:
git clone https://github.com/your-username/java-dsa-handbook.git cd java-dsa-handbook
-
Compile and run any file (e.g.
App.java
)javac App.java java App
-
Or open the folder in your IDE and explore modules interactively.
Module | Topics Included |
---|---|
Arrays | Traversal, prefix sums, sliding window |
Bits | XOR, shifts, bit masking |
Dynamic Programming | LIS, Catalan, Coin Change, String Matching |
Graph | DFS, BFS, Union-Find, Adjacency list |
Greedy | Activity selection, Huffman coding basics |
HashMap | Frequency count, custom hashing |
Heap | Priority Queue, Min/Max Heaps |
LinkedList | Singly/Double LL, reversal, merging |
Matrix | Search in matrix, spiral traversal |
Queue | Linear & Circular Queues, Deque |
Recursion | Backtracking, subsequences, permutations |
Searching & Sorting | Binary search, merge/quick sort |
Stack | Balanced parentheses, infix to postfix |
Tree | BST, AVL, Binary Tree traversal, Generic Trees |
Trie | Prefix Tree creation, search, insertion |
- 📘 Students preparing for DSA courses and college exams
- 💼 Job seekers preparing for coding rounds in companies
- 🧑💻 Developers refreshing core DSA fundamentals
- 🏆 Competitive coders looking to organize solutions
In addition to the code, this repository is supplemented with 1000+ curated DSA questions categorized by topic along with detailed theory notes.
📎 Access the complete DSA question bank & theory notes
This document is ideal for:
- Interview preparation
- Practice on LeetCode, GFG, etc.
- Topic-wise revision and concept reinforcement
Udit Jain
- 🌐 Portfolio: uditjain100.github.io
- 📫 Email: [email protected]
- 🧑💻 GitHub: @uditjain100