MSMuppidi Srinivasinsrinivastechblog.hashnode.dev·Mar 16 · 4 min readSliding Window Technique: A Powerful Tool for Subarray ProblemsSliding Window Technique When solving array or string problems in competitive programming, we often deal with subarrays or substrings. A naive solution usually checks every possible subarray, which le00
MSMuppidi Srinivasinsrinivastechblog.hashnode.dev·Mar 16 · 10 min readUnderstanding Graphs, Recursion, and Depth First Search (DFS) Introduction to Graphs A graph consists of : Nodes (Vertices) → entities Edges → connections between nodes Example : Students in a classroom and their friendships. 1 — 2 | | 3 — 4 Here : Node 00
MSMuppidi Srinivasinsrinivastechblog.hashnode.dev·Feb 23 · 11 min readMastering Fenwick Tree for Competitive ProgrammingWhile reading, don’t overthink or get stuck. Just follow along with the flow—you’ll understand everything step by step as we go. Given ArrayIndex : 0 1 2 3 4 5 6Array : 3 2 00
MSMuppidi Srinivasinsrinivastechblog.hashnode.dev·Feb 21 · 10 min readMo’s Algorithm – Step by Step GuideMo’s Algorithm is a technique used to answer range queries efficiently on arrays You are given : An array A Many queries: [L, R] Each query asks something like : sum of elements number of dis00
MSMuppidi Srinivasinsrinivastechblog.hashnode.dev·Feb 21 · 6 min readEfficient Range Queries Using Sqrt DecompositionSquare Root Decomposition is a technique used to answer range queries efficiently. When do we use it? When you have : An array A[0…N-1] Many queries like : Sum of range [L, R] Min/Max in range C00