3-Month DSA with Java Roadmap
This roadmap is designed to make you job-ready in Data Structures and Algorithms (DSA)
using Java. It covers all core and advanced topics, suitable for coding interviews at product-
based companies.
Month 1: Core Java + Foundation DSA
Week 1: Java + Arrays
Java Syntax, Input/Output, Classes, OOPs
Arrays: Sorting, Searching, Sliding Window
Practice: 10–15 LeetCode Easy-Medium problems
Week 2: Recursion + Backtracking
Recursion Tree, Stack Trace
Backtracking: N-Queens, Subsets, Maze, Sudoku
Practice: 10–12 problems
Week 3: Strings + Bit Manipulation
Palindromes, Anagrams, Z-algorithm (basic intro)
Bitwise: XOR, Counting bits, Power of 2
Practice: 15 problems
Week 4: Linked Lists
Singly/Doubly/Circular LL
Detect loop, Reverse in K groups, Merge LL
Practice: 15 problems
Month 2: Intermediate DSA
Week 5: Stacks & Queues
Stack: Infix, Prefix, Next Greater Element
Queue: Deque, Stack from Queue, LRU (design)
Practice: 15+ problems
Week 6: Trees + BST
Tree Traversals, Height, Diameter, LCA
BST Insert/Delete, Validate BST, Kth Smallest
Practice: 20 problems
Week 7: Heaps + Tries
Heaps: Min/Max, Heap Sort, K Closest Elements
Tries: Insert, Search, StartsWith, Count Prefix
Trie apps: Word Dictionary, Longest Common Prefix
Practice: 10 Trie problems (LeetCode Hard/Easy mix)
Week 8: Hashing + Sliding Window
HashMap, HashSet, Frequency Maps
Sliding Window, Two Pointer Tricks
Practice: 20 problems
Month 3: Advanced + Interview Prep
Week 9: Graphs I
Graph Representation, BFS, DFS
Cycle Detection (Undirected/Directed), Connected Components
Practice: 10–15 problems
Week 10: Graphs II (Advanced)
Topo Sort (Kahn’s Algo), Dijkstra, Prim, Kruskal, DSU
Bridges/Articulation Points (optional)
Practice: 15–20 problems
Week 11: Dynamic Programming
Memoization, Tabulation: Fib, Climb Stairs, Knapsack
DP on Arrays, Subsets, Strings
Practice: 15–20 problems
Week 12: Segment Tree + Bitmasking + Mock Interviews
Segment Tree, Lazy Propagation (basic)
Bitmasking: Subset DP, Traveling Salesman DP (intro)
Mock Interviews + Resume polishing + Revisions
Practice: 10 Segment Tree / Bitmask problems