├── .gitignore ├── 01. Time Complexity ├── 1.order_of_growth.md ├── 2.asymptotic_notation.md └── 3.space.md ├── 02. Mathematics ├── 01.CountDigit │ └── countDigit.cpp ├── 02.Palindrome │ └── palindrome.cpp ├── 03.Factorial │ └── fact.cpp ├── 04.CountTrailZero │ └── countTrailZero.cpp ├── 05.GCD │ └── GCD.cpp ├── 06.LCM │ └── LCM.cpp ├── 07.Prime │ └── prime.cpp ├── 08.PrimeFactors │ └── primeFactors.cpp ├── 09.AllDivisiors │ └── allDivisor.cpp ├── 10.SieveOfEratosthenes │ └── primeInRange.cpp ├── 11.Power │ └── power.cpp ├── 12. Exactly 3 Divisor │ └── divisor.cpp └── 13. FastExponent │ └── exponent.cpp ├── 03. Bit Magic ├── 01. Theory │ └── BitwiseOperators.md ├── 02. Operations │ └── Bitwise.cpp ├── 03. CheckKthBit │ └── checkBit.cpp ├── 04. RightMostDiffBit │ └── rightMostDiffBit.cpp ├── 05. CountSetBit │ └── countBit.cpp ├── 06. BitInRange │ └── bitInRange.cpp ├── 07. PowerOfTwo │ └── po2.cpp ├── 08. Missing number │ └── missing.cpp ├── 09. SwapEvenOdd │ └── swap.cpp └── 10. Only odd occuring │ └── odd.cpp ├── 04. Recursion ├── 01. Theory │ └── recursion.md ├── 02. Guess Output │ └── guess.cpp ├── 03. Print Numbers │ └── printNumber.cpp ├── 04. Fact and Fibo │ └── FactnFibo.cpp ├── 05. Palindrome │ └── palindrome.cpp ├── 06. Sum of Digits │ └── sum.cpp ├── 07. Rope cutting │ └── rope.cpp ├── 08. Generate Subset │ └── subset.cpp ├── 09. Tower of Hanoi │ └── toh.cpp └── 10. Josephus │ └── jose.cpp ├── 05. Array ├── 01. Theory │ ├── introduction.md │ └── vector.md ├── 02. Array │ └── operations.cpp ├── 03.Vector │ └── vector.cpp ├── 04. Largest Element │ └── large.cpp ├── 05. Check sorted │ └── check.cpp ├── 06. Reverse │ └── reverse.cpp ├── 07. Remove Duplicate │ └── remove.cpp ├── 08. Segregate │ └── move.cpp ├── 09. Left Rotate │ └── rotate.cpp ├── 10. Right Rotate │ └── rotate.cpp ├── 11. Max difference │ └── maxDiff.cpp ├── 12. Frequency │ └── freq.cpp ├── 13. Stock │ └── stock.cpp ├── 14. Rain Water │ └── rain.cpp ├── 15. Consecutive ones │ └── countOnes.cpp ├── 16. Sub Array │ └── subArray.cpp ├── 17. SubArray sum │ └── sum.cpp ├── 18. Max Even Odd │ └── max.cpp ├── 19. Rearrange Alternately │ └── rearrange.cpp ├── 20. Circular subarray │ └── cSub.cpp ├── 21. Majority │ └── majority.cpp ├── 22. Good pair │ └── good.cpp ├── 23. Max Sum │ └── max.cpp ├── 24. Min Consecutive flips │ └── flips.cpp ├── 25. Sliding Window │ ├── constant.cpp │ └── variable.cpp ├── 26. Subarray │ └── sum.cpp ├── 27. sort rotate │ └── sortedRotated.cpp ├── 28. Subset sum │ └── subsetsum.cpp ├── 29. Max Area │ └── max.cpp └── 30. Absolute Diff │ └── minimize.cpp ├── 06. Searching ├── 01. Binary Search (Iterative) │ └── binary.cpp ├── 02. BInary Search (recursive) │ └── binary.cpp ├── 03. Index of First occurance │ └── index.cpp ├── 04. Index of Last Occurance │ └── index.cpp ├── 05. Freq in sorted array │ └── freq.cpp ├── 06. Sqrt Floor │ └── sqrt.cpp ├── 07. Print all perfect squares │ └── square.cpp ├── 08. Search in sorted rotated array │ └── search.cpp ├── 09. Peak element │ └── peak.cpp ├── 10. Two pointer │ └── pointer.cpp ├── 11. Median in sorted array │ └── median.cpp └── 12. Repeating element │ └── repeat.cpp ├── 07. Sorting ├── 01. Theory │ ├── sort.md │ └── stability.md ├── 02. Bubble Sort │ └── bubble.cpp ├── 03. Selection Sort │ └── selection.cpp ├── 04. Insertion Sort │ └── Insertion.cpp ├── 05. Merge sorted array │ └── merge.cpp ├── 06. Merge function │ └── merge.cpp ├── 07. Merge sort │ └── merge.cpp ├── 08. Union │ └── union.cpp ├── 09. Intersection │ └── intersection.cpp ├── 10. Count Inversion │ └── count.cpp ├── 11. Naive partition │ └── partition.cpp ├── 12. Lomuto partition │ └── partition.cpp ├── 13. Hoare's partition │ └── partition.cpp ├── 14. QuickSort Lomuto │ └── sort.cpp ├── 15. QuickSort Hoare │ └── sort.cpp ├── 16. Kth Smallest │ └── smallest.cpp ├── 17. Chocolate distribution │ └── chocolate.cpp ├── 18. Sort and segregate │ └── sort.cpp ├── 19. Min Difference │ └── min.cpp ├── 20. Mege intervals │ └── merge.cpp └── 21. Max guests │ └── guests.cpp ├── 08. Matrix ├── 01. Introduction │ └── matrix.cpp ├── 02. Array as parameters │ └── parameter.cpp ├── 03. Snake pattern │ └── print.cpp ├── 04. Spiral pattern │ └── spiral.cpp ├── 05. Transpose │ └── transpose.cpp ├── 06. Rotate │ └── rotate.cpp ├── 07. Search │ └── search.cpp ├── 08. Print diagonals │ └── diagonal.cpp └── 09. Sort diagonally │ └── sort.cpp ├── 09. Hashing ├── 01. Theory │ └── theory.md ├── 02. Implementation │ └── implement.cpp ├── 03. Count distinct │ └── count.cpp ├── 04. Print freq │ └── print.cpp ├── 05. Intersection │ └── intersection.cpp ├── 06. Union │ └── union.cpp ├── 07. Find pair │ └── pair.cpp ├── 08. Subarray sum 0 │ └── sum.cpp ├── 09. Count subarray │ └── count.cpp ├── 10. Count 0 and 1 │ └── count.cpp ├── 11. Largest subarray │ └── find.cpp ├── 12. Longest subsequence │ └── longest.cpp ├── 13. Distinct elements │ └── count.cpp ├── 14. More than NbyK │ └── count.cpp ├── 15. Sort by freq │ └── sort.cpp ├── 16. winner │ └── winner.cpp ├── 17. Group Anagram │ └── anagram.cpp └── 18. Smaller Right │ └── smaller.cpp ├── 10. Strings ├── 01. Theory │ └── theory.md ├── 02. Operations │ └── operations.cpp ├── 03. Split and store │ └── string.cpp ├── 04. Letter frequency │ └── freq.cpp ├── 05. Word frequency │ └── freq.cpp ├── 06. Palindrome │ └── palindrome.cpp ├── 07. Subsequence │ ├── checkSubsequence.cpp │ └── printSubsequence.cpp ├── 08. Anagram │ └── anagram.cpp ├── 09. First Repeating │ └── repeat.cpp ├── 10. First non-repeating │ └── nonRepeating.cpp ├── 11. Reverse words │ └── reverse.cpp ├── 12. Naive search │ └── pattern.cpp ├── 13. Improved Naive │ └── search.cpp ├── 14. Rabin Karp Algorithm │ └── rk.cpp ├── 15. KMP algorithm │ ├── 1_lps.cpp │ └── kmp.cpp ├── 16. Check Rotated │ └── check.cpp ├── 17. Anagram search │ └── search.cpp ├── 18. Lexicographic rank │ └── rank.cpp ├── 19. Distinct characters │ └── longest.cpp ├── 20. Pangram │ └── pangram.cpp ├── 21. LargestNumber │ └── largest.cpp └── 22. K distinctChar │ └── kdistinct.cpp ├── 11. Pointers ├── 01. Introduction │ ├── 1. Pointer.md │ ├── 2. Double Pointer.md │ ├── pointer-to-pointer.webp │ └── pointers-in-c.png ├── 02. Basics │ └── pointer.cpp ├── 03 .swap │ └── swap.cpp ├── 04. Pointer to array │ └── array.cpp ├── 05. Pointer to structure │ └── structure.cpp ├── 06. Pointer to function │ └── function.cpp └── 07. Pointer Arithmatic │ └── arithmetic.cpp ├── 12. Linked List ├── 01. Theory │ ├── linkedlist.png │ └── theory.md ├── 02. SLL │ ├── 01. Singly Linked List │ │ ├── link.cpp │ │ ├── list.cpp │ │ └── listlinked.cpp │ ├── 02. Traverse │ │ └── traverse.cpp │ ├── 03. Insert begin │ │ └── insert.cpp │ ├── 04. Insert end │ │ └── insert.cpp │ ├── 05. Delete head │ │ └── delete.cpp │ ├── 06. Delete tail │ │ └── delete.cpp │ ├── 07. Insert at pos │ │ └── insert.cpp │ ├── 08. Search │ │ └── search.cpp │ ├── 09. Reverse │ │ └── reverse.cpp │ └── Master │ │ └── list.cpp ├── 03 DLL │ ├── 01. Doubly Linked List │ │ └── doublyLL.cpp │ ├── 02. Insert begin │ │ └── insert.cpp │ ├── 03. Insert end │ │ └── insert.cpp │ ├── 04. Delete head │ │ └── delete.cpp │ ├── 05. Delete tail │ │ └── delete.cpp │ ├── 06. Insert at pos │ │ └── insert.cpp │ ├── 07 Reverse │ │ └── revDoublyLL.cpp │ ├── 08. Search │ │ └── search.cpp │ └── Master │ │ └── list.cpp ├── 04. SCLL │ ├── 01. Singly Circular LL │ │ └── singlyCircular.cpp │ ├── 02. Traverse │ │ └── traverse.cpp │ ├── 03. Insert begin │ │ └── insert.cpp │ ├── 04. Insert end │ │ └── insert.cpp │ ├── 05. Delete head │ │ └── delete.cpp │ ├── 06. Delete tail │ │ └── delete.cpp │ └── 07. Delete kth node │ │ └── delete.cpp ├── 05. CDLL │ ├── 01. Circular Doubly LL │ │ └── cdll.cpp │ ├── 02. Traverse │ │ └── traverse.cpp │ └── 03. Insert begin │ │ └── insert.cpp └── 06. Questions │ ├── 01. Sorted insert │ └── sorted.cpp │ ├── 02. Middle item │ └── center.cpp │ ├── 03. Nth from end │ └── printnode.cpp │ ├── 04. Reverse │ └── reverse.cpp │ ├── 05. Remove dups │ └── remove.cpp │ ├── 06. Reverse in group │ └── rev.cpp │ ├── 07. Detect loop │ └── detect.cpp │ ├── 08. Cycle detection │ └── floyd.cpp │ ├── 09. Remove loop │ └── remove.cpp │ ├── 10. Segregate node │ ├── byIndex.cpp │ └── segregate.cpp │ ├── 11. Intersection │ └── common.cpp │ ├── 12. Pairwise swap │ └── swap.cpp │ ├── 13. Random ptr │ └── random.cpp │ ├── 14. Merge │ └── merge.cpp │ ├── 15. Palindrome │ └── palindrome.cpp │ ├── 16. Add two number │ └── add.cpp │ ├── 17. Rotate │ └── rotate.cpp │ ├── 18. Merge Sort │ └── mergesort.cpp │ └── 19. Reverse in range │ └── revese.cpp ├── 13. Stack ├── 01. Theory │ └── Theory.md ├── 02. Implementation │ ├── 1_Array.cpp │ ├── 2_Vector.cpp │ └── 3_List.cpp ├── 03. Balanced bracket │ └── balanced.cpp ├── 04. Two stack │ └── twoStack.cpp ├── 05. Stock span │ └── span.cpp ├── 06. Previous greater │ └── prevMax.cpp ├── 07. Next greater │ └── nextMax.cpp ├── 08. Previous smaller │ └── prevMin.cpp ├── 09. Next Smaller │ └── nextMin.cpp ├── 10. Histogram area │ ├── _prerequisite.cpp │ └── maxArea.cpp └── 11. Infix Prefix Posfix │ └── Theory.md ├── 14. Queue ├── 01. Theory │ └── queue.md ├── 02. Implementation │ ├── queueArr.cpp │ └── queueList.cpp └── 03. Generate numbers │ └── generate.cpp ├── 15. Deque ├── 01. Theory │ └── theory.md ├── 02. Implementation │ └── dequeArr.cpp └── 03. Max of subarrayK │ └── max.cpp ├── 16. Greedy ├── 01. Theory │ └── theory.md ├── 02. Minimum Coins │ └── minimum.cpp ├── 03. Activity selection │ └── activity.cpp ├── 04. Fractional Knapsack │ └── knapsack.cpp └── 05. Job sequencing │ └── job.cpp ├── 17. Tree ├── 01. Theory │ └── theory.md ├── 02. Implementation │ └── implement.cpp ├── 03. Traversal │ └── traverse.md ├── 04. Depth First Traversal │ ├── 1_inorder_recursive.cpp │ ├── 2_inorder_iterative.cpp │ ├── 3_preorder_recursive.cpp │ ├── 4_preorder_iterative.cpp │ ├── 5_postorder_recursive.cpp │ └── 6_postorder_iterative.cpp ├── 05. Height │ └── height.cpp ├── 06. Print at K distance │ └── print.cpp ├── 07. Breadth First Traversal │ ├── 1_usingtwoFunction.cpp │ ├── 2_usingQueue.cpp │ ├── 3_NewLineWithNULL.cpp │ └── 4_NewLineWithLoop.cpp ├── 08. Count Nodes │ └── count.cpp ├── 09. Maximum │ └── max.cpp ├── 10. Left View │ └── left.cpp ├── 11 Right view │ └── right.cpp ├── 12. Child Sum │ └── sum.cpp ├── 13. Height Balanced │ └── balanced.cpp ├── 14. Width │ └── width.cpp ├── 15. Convert to DLL │ └── dll.cpp ├── 16. Construct tree │ └── construct.cpp ├── 17. Snake Pattern │ └── snake.cpp ├── 18. Diameter │ └── diameter.cpp ├── 19. Compare │ └── checkEqual.cpp ├── 20. Check Subtree │ └── check.cpp ├── 21. Count Subtree │ └── count.cpp ├── 22. Max Pathsum │ └── maxpath.cpp ├── 23. Mirror Tree │ └── mirror.cpp ├── 24. Vertical width │ └── width.cpp ├── 25. Connect Nodes │ └── connect.cpp ├── 26. List to Tree │ └── tree.cpp ├── 27. Foldable Tree │ └── fold.cpp ├── 28. Check CBT │ └── check.cpp ├── 29. Diagonal Tree │ └── diagonal.cpp ├── 30. Boundary │ └── boundary.cpp └── 31. Built Tree │ └── build.cpp ├── 18. Binary Search Tree ├── 01. Theory │ └── theory.md ├── 02. Implementation │ └── implement.cpp ├── 03. Search │ └── search.cpp ├── 04. Insert │ └── insert.cpp ├── 05. Delete │ └── delete.cpp ├── 06. Floor │ └── floor.cpp ├── 07. Ceil │ └── ceil.cpp ├── 08. Range BST │ └── range.cpp ├── 09. Range Count │ └── range.cpp ├── 10. Pair Sum │ └── pair.cpp ├── 11. Vertical Traversal │ └── vertical.cpp ├── 12. Veritcal Sum │ └── vertical.cpp ├── 13. Top View │ └── top.cpp └── 14. Bottom View │ └── bottom.cpp ├── 19. Graph ├── 01. Theory │ ├── Graph.png │ └── theory.md ├── 02. Implementation │ ├── graph_1_a.cpp │ ├── graph_1_a.png │ ├── graph_1_b.cpp │ ├── graph_1_b.png │ ├── graph_2_a.cpp │ ├── graph_2_a.png │ ├── graph_2_b.cpp │ ├── graph_2_b.png │ └── graph_3.cpp ├── 03. DFS │ ├── 01_dfs.cpp │ ├── 02_dfs.cpp │ ├── 03_dfs_itr.cpp │ └── 04_dfs_naray.cpp ├── 04. Cond Comp │ └── CC.cpp ├── 06. SSSP │ ├── 01_sssp.cpp │ ├── 02_ques.cpp │ └── 03_ques.cpp ├── 07. Bipartite │ ├── 01_bp.cpp │ └── 02_ques.cpp ├── 08. Cycle Detection │ ├── 01_findCycle.cpp │ ├── 02_printCycle.cpp │ └── 03_directed.cpp ├── 09. Problem │ └── codechef.cpp ├── 10. InOut │ └── inout.cpp ├── 11. Diameter │ └── ques.cpp ├── 12. Subtree Size │ └── subtree.cpp ├── 13. BFS │ ├── 01_bfs.cpp │ └── 02_bfs.cpp ├── 14. SSSP │ └── sssp_bfs.cpp ├── 15. Prime Path │ └── prime.cpp ├── 16. Feasible Relations │ └── relations.cpp ├── 17. Social Networking │ └── social.cpp ├── 18. Word Ladder │ └── word.cpp ├── 19. Print paths │ └── print.cpp ├── 20. Bridges │ ├── 01_bridges.cpp │ └── 02_ques.cpp ├── 21. Articulation Points │ └── cutVertices.cpp ├── 22. Topological Sort │ ├── 01_bfstopo.cpp │ ├── 02_dfstopo.cpp │ ├── 03_ques.cpp │ ├── 04_sssp_dag.cpp │ └── 05_cycle.cpp ├── 23. DFS Grid │ ├── 01_dfs.cpp │ └── 02_dfs.cpp ├── 24. Cond Comp │ ├── 01_cc.cpp │ └── 02_cc.cpp ├── 25. BFS │ ├── 01_bfs.cpp │ ├── 02_bfs.cpp │ ├── 03_bfs.cpp │ └── 04_bfs.cpp ├── 26. Min Moves │ └── knight.cpp ├── 27. Kosaraju's Algo │ └── kosaraju.cpp ├── 28. Tarjan's Algo │ └── tarjan.cpp ├── 29. Prim's algo │ └── prim.cpp └── 30. Kruskal's algo │ ├── dsu.cpp │ └── kruskal.cpp ├── README.md └── _Utility ├── 01. Preprocessors └── preprocessor.cpp ├── 02. Builtin functions └── builtInFn.cpp ├── 03. vector └── vector.cpp ├── 04. pair └── pair.cpp ├── 05. set └── set.c++ ├── 06. map └── map.cpp ├── 07. Strings └── strings.cpp ├── 08. List └── list.cpp ├── 09. stack └── stack.cpp └── _images └── demo.png /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/.gitignore -------------------------------------------------------------------------------- /01. Time Complexity/1.order_of_growth.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/01. Time Complexity/1.order_of_growth.md -------------------------------------------------------------------------------- /01. Time Complexity/2.asymptotic_notation.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/01. Time Complexity/2.asymptotic_notation.md -------------------------------------------------------------------------------- /01. Time Complexity/3.space.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/01. Time Complexity/3.space.md -------------------------------------------------------------------------------- /02. Mathematics/01.CountDigit/countDigit.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/01.CountDigit/countDigit.cpp -------------------------------------------------------------------------------- /02. Mathematics/02.Palindrome/palindrome.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/02.Palindrome/palindrome.cpp -------------------------------------------------------------------------------- /02. Mathematics/03.Factorial/fact.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/03.Factorial/fact.cpp -------------------------------------------------------------------------------- /02. Mathematics/04.CountTrailZero/countTrailZero.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/04.CountTrailZero/countTrailZero.cpp -------------------------------------------------------------------------------- /02. Mathematics/05.GCD/GCD.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/05.GCD/GCD.cpp -------------------------------------------------------------------------------- /02. Mathematics/06.LCM/LCM.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/06.LCM/LCM.cpp -------------------------------------------------------------------------------- /02. Mathematics/07.Prime/prime.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/07.Prime/prime.cpp -------------------------------------------------------------------------------- /02. Mathematics/08.PrimeFactors/primeFactors.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/08.PrimeFactors/primeFactors.cpp -------------------------------------------------------------------------------- /02. Mathematics/09.AllDivisiors/allDivisor.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/09.AllDivisiors/allDivisor.cpp -------------------------------------------------------------------------------- /02. Mathematics/10.SieveOfEratosthenes/primeInRange.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/10.SieveOfEratosthenes/primeInRange.cpp -------------------------------------------------------------------------------- /02. Mathematics/11.Power/power.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/11.Power/power.cpp -------------------------------------------------------------------------------- /02. Mathematics/12. Exactly 3 Divisor/divisor.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/12. Exactly 3 Divisor/divisor.cpp -------------------------------------------------------------------------------- /02. Mathematics/13. FastExponent/exponent.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/02. Mathematics/13. FastExponent/exponent.cpp -------------------------------------------------------------------------------- /03. Bit Magic/01. Theory/BitwiseOperators.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/03. Bit Magic/01. Theory/BitwiseOperators.md -------------------------------------------------------------------------------- /03. Bit Magic/02. Operations/Bitwise.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/03. Bit Magic/02. Operations/Bitwise.cpp -------------------------------------------------------------------------------- /03. Bit Magic/03. CheckKthBit/checkBit.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/03. Bit Magic/03. CheckKthBit/checkBit.cpp -------------------------------------------------------------------------------- /03. Bit Magic/04. RightMostDiffBit/rightMostDiffBit.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/03. Bit Magic/04. RightMostDiffBit/rightMostDiffBit.cpp -------------------------------------------------------------------------------- /03. Bit Magic/05. CountSetBit/countBit.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/03. Bit Magic/05. CountSetBit/countBit.cpp -------------------------------------------------------------------------------- /03. Bit Magic/06. BitInRange/bitInRange.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/03. Bit Magic/06. BitInRange/bitInRange.cpp -------------------------------------------------------------------------------- /03. Bit Magic/07. PowerOfTwo/po2.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/03. Bit Magic/07. PowerOfTwo/po2.cpp -------------------------------------------------------------------------------- /03. Bit Magic/08. Missing number/missing.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/03. Bit Magic/08. Missing number/missing.cpp -------------------------------------------------------------------------------- /03. Bit Magic/09. SwapEvenOdd/swap.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/03. Bit Magic/09. SwapEvenOdd/swap.cpp -------------------------------------------------------------------------------- /03. Bit Magic/10. Only odd occuring/odd.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/03. Bit Magic/10. Only odd occuring/odd.cpp -------------------------------------------------------------------------------- /04. Recursion/01. Theory/recursion.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/04. Recursion/01. Theory/recursion.md -------------------------------------------------------------------------------- /04. Recursion/02. Guess Output/guess.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/04. Recursion/02. Guess Output/guess.cpp -------------------------------------------------------------------------------- /04. Recursion/03. Print Numbers/printNumber.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/04. Recursion/03. Print Numbers/printNumber.cpp -------------------------------------------------------------------------------- /04. Recursion/04. Fact and Fibo/FactnFibo.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/04. Recursion/04. Fact and Fibo/FactnFibo.cpp -------------------------------------------------------------------------------- /04. Recursion/05. Palindrome/palindrome.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/04. Recursion/05. Palindrome/palindrome.cpp -------------------------------------------------------------------------------- /04. Recursion/06. Sum of Digits/sum.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/04. Recursion/06. Sum of Digits/sum.cpp -------------------------------------------------------------------------------- /04. Recursion/07. Rope cutting/rope.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/04. Recursion/07. Rope cutting/rope.cpp -------------------------------------------------------------------------------- /04. Recursion/08. Generate Subset/subset.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/04. Recursion/08. Generate Subset/subset.cpp -------------------------------------------------------------------------------- /04. Recursion/09. Tower of Hanoi/toh.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/04. Recursion/09. Tower of Hanoi/toh.cpp -------------------------------------------------------------------------------- /04. Recursion/10. Josephus/jose.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/04. Recursion/10. Josephus/jose.cpp -------------------------------------------------------------------------------- /05. Array/01. Theory/introduction.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/01. Theory/introduction.md -------------------------------------------------------------------------------- /05. Array/01. Theory/vector.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/01. Theory/vector.md -------------------------------------------------------------------------------- /05. Array/02. Array/operations.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/02. Array/operations.cpp -------------------------------------------------------------------------------- /05. Array/03.Vector/vector.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/03.Vector/vector.cpp -------------------------------------------------------------------------------- /05. Array/04. Largest Element/large.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/04. Largest Element/large.cpp -------------------------------------------------------------------------------- /05. Array/05. Check sorted/check.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/05. Check sorted/check.cpp -------------------------------------------------------------------------------- /05. Array/06. Reverse/reverse.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/06. Reverse/reverse.cpp -------------------------------------------------------------------------------- /05. Array/07. Remove Duplicate/remove.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/07. Remove Duplicate/remove.cpp -------------------------------------------------------------------------------- /05. Array/08. Segregate/move.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/08. Segregate/move.cpp -------------------------------------------------------------------------------- /05. Array/09. Left Rotate/rotate.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/09. Left Rotate/rotate.cpp -------------------------------------------------------------------------------- /05. Array/10. Right Rotate/rotate.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/10. Right Rotate/rotate.cpp -------------------------------------------------------------------------------- /05. Array/11. Max difference/maxDiff.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/11. Max difference/maxDiff.cpp -------------------------------------------------------------------------------- /05. Array/12. Frequency/freq.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/12. Frequency/freq.cpp -------------------------------------------------------------------------------- /05. Array/13. Stock/stock.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/13. Stock/stock.cpp -------------------------------------------------------------------------------- /05. Array/14. Rain Water/rain.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/14. Rain Water/rain.cpp -------------------------------------------------------------------------------- /05. Array/15. Consecutive ones/countOnes.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/15. Consecutive ones/countOnes.cpp -------------------------------------------------------------------------------- /05. Array/16. Sub Array/subArray.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/16. Sub Array/subArray.cpp -------------------------------------------------------------------------------- /05. Array/17. SubArray sum/sum.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/17. SubArray sum/sum.cpp -------------------------------------------------------------------------------- /05. Array/18. Max Even Odd/max.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/18. Max Even Odd/max.cpp -------------------------------------------------------------------------------- /05. Array/19. Rearrange Alternately/rearrange.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/19. Rearrange Alternately/rearrange.cpp -------------------------------------------------------------------------------- /05. Array/20. Circular subarray/cSub.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/20. Circular subarray/cSub.cpp -------------------------------------------------------------------------------- /05. Array/21. Majority/majority.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/21. Majority/majority.cpp -------------------------------------------------------------------------------- /05. Array/22. Good pair/good.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/22. Good pair/good.cpp -------------------------------------------------------------------------------- /05. Array/23. Max Sum/max.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/23. Max Sum/max.cpp -------------------------------------------------------------------------------- /05. Array/24. Min Consecutive flips/flips.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/24. Min Consecutive flips/flips.cpp -------------------------------------------------------------------------------- /05. Array/25. Sliding Window/constant.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/25. Sliding Window/constant.cpp -------------------------------------------------------------------------------- /05. Array/25. Sliding Window/variable.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/25. Sliding Window/variable.cpp -------------------------------------------------------------------------------- /05. Array/26. Subarray/sum.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/26. Subarray/sum.cpp -------------------------------------------------------------------------------- /05. Array/27. sort rotate/sortedRotated.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/27. sort rotate/sortedRotated.cpp -------------------------------------------------------------------------------- /05. Array/28. Subset sum/subsetsum.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/28. Subset sum/subsetsum.cpp -------------------------------------------------------------------------------- /05. Array/29. Max Area/max.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/29. Max Area/max.cpp -------------------------------------------------------------------------------- /05. Array/30. Absolute Diff/minimize.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/05. Array/30. Absolute Diff/minimize.cpp -------------------------------------------------------------------------------- /06. Searching/01. Binary Search (Iterative)/binary.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/06. Searching/01. Binary Search (Iterative)/binary.cpp -------------------------------------------------------------------------------- /06. Searching/02. BInary Search (recursive)/binary.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/06. Searching/02. BInary Search (recursive)/binary.cpp -------------------------------------------------------------------------------- /06. Searching/03. Index of First occurance/index.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/06. Searching/03. Index of First occurance/index.cpp -------------------------------------------------------------------------------- /06. Searching/04. Index of Last Occurance/index.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/06. Searching/04. Index of Last Occurance/index.cpp -------------------------------------------------------------------------------- /06. Searching/05. Freq in sorted array/freq.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/06. Searching/05. Freq in sorted array/freq.cpp -------------------------------------------------------------------------------- /06. Searching/06. Sqrt Floor/sqrt.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/06. Searching/06. Sqrt Floor/sqrt.cpp -------------------------------------------------------------------------------- /06. Searching/07. Print all perfect squares/square.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/06. Searching/07. Print all perfect squares/square.cpp -------------------------------------------------------------------------------- /06. Searching/08. Search in sorted rotated array/search.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/06. Searching/08. Search in sorted rotated array/search.cpp -------------------------------------------------------------------------------- /06. Searching/09. Peak element/peak.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/06. Searching/09. Peak element/peak.cpp -------------------------------------------------------------------------------- /06. Searching/10. Two pointer/pointer.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/06. Searching/10. Two pointer/pointer.cpp -------------------------------------------------------------------------------- /06. Searching/11. Median in sorted array/median.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/06. Searching/11. Median in sorted array/median.cpp -------------------------------------------------------------------------------- /06. Searching/12. Repeating element/repeat.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/06. Searching/12. Repeating element/repeat.cpp -------------------------------------------------------------------------------- /07. Sorting/01. Theory/sort.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/01. Theory/sort.md -------------------------------------------------------------------------------- /07. Sorting/01. Theory/stability.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/01. Theory/stability.md -------------------------------------------------------------------------------- /07. Sorting/02. Bubble Sort/bubble.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/02. Bubble Sort/bubble.cpp -------------------------------------------------------------------------------- /07. Sorting/03. Selection Sort/selection.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/03. Selection Sort/selection.cpp -------------------------------------------------------------------------------- /07. Sorting/04. Insertion Sort/Insertion.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/04. Insertion Sort/Insertion.cpp -------------------------------------------------------------------------------- /07. Sorting/05. Merge sorted array/merge.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/05. Merge sorted array/merge.cpp -------------------------------------------------------------------------------- /07. Sorting/06. Merge function/merge.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/06. Merge function/merge.cpp -------------------------------------------------------------------------------- /07. Sorting/07. Merge sort/merge.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/07. Merge sort/merge.cpp -------------------------------------------------------------------------------- /07. Sorting/08. Union/union.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/08. Union/union.cpp -------------------------------------------------------------------------------- /07. Sorting/09. Intersection/intersection.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/09. Intersection/intersection.cpp -------------------------------------------------------------------------------- /07. Sorting/10. Count Inversion/count.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/10. Count Inversion/count.cpp -------------------------------------------------------------------------------- /07. Sorting/11. Naive partition/partition.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/11. Naive partition/partition.cpp -------------------------------------------------------------------------------- /07. Sorting/12. Lomuto partition/partition.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/12. Lomuto partition/partition.cpp -------------------------------------------------------------------------------- /07. Sorting/13. Hoare's partition/partition.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/13. Hoare's partition/partition.cpp -------------------------------------------------------------------------------- /07. Sorting/14. QuickSort Lomuto/sort.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/14. QuickSort Lomuto/sort.cpp -------------------------------------------------------------------------------- /07. Sorting/15. QuickSort Hoare/sort.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/15. QuickSort Hoare/sort.cpp -------------------------------------------------------------------------------- /07. Sorting/16. Kth Smallest/smallest.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/16. Kth Smallest/smallest.cpp -------------------------------------------------------------------------------- /07. Sorting/17. Chocolate distribution/chocolate.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/17. Chocolate distribution/chocolate.cpp -------------------------------------------------------------------------------- /07. Sorting/18. Sort and segregate/sort.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/18. Sort and segregate/sort.cpp -------------------------------------------------------------------------------- /07. Sorting/19. Min Difference/min.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/19. Min Difference/min.cpp -------------------------------------------------------------------------------- /07. Sorting/20. Mege intervals/merge.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/20. Mege intervals/merge.cpp -------------------------------------------------------------------------------- /07. Sorting/21. Max guests/guests.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/07. Sorting/21. Max guests/guests.cpp -------------------------------------------------------------------------------- /08. Matrix/01. Introduction/matrix.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/08. Matrix/01. Introduction/matrix.cpp -------------------------------------------------------------------------------- /08. Matrix/02. Array as parameters/parameter.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/08. Matrix/02. Array as parameters/parameter.cpp -------------------------------------------------------------------------------- /08. Matrix/03. Snake pattern/print.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/08. Matrix/03. Snake pattern/print.cpp -------------------------------------------------------------------------------- /08. Matrix/04. Spiral pattern/spiral.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/08. Matrix/04. Spiral pattern/spiral.cpp -------------------------------------------------------------------------------- /08. Matrix/05. Transpose/transpose.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/08. Matrix/05. Transpose/transpose.cpp -------------------------------------------------------------------------------- /08. Matrix/06. Rotate/rotate.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/08. Matrix/06. Rotate/rotate.cpp -------------------------------------------------------------------------------- /08. Matrix/07. Search/search.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/08. Matrix/07. Search/search.cpp -------------------------------------------------------------------------------- /08. Matrix/08. Print diagonals/diagonal.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/08. Matrix/08. Print diagonals/diagonal.cpp -------------------------------------------------------------------------------- /08. Matrix/09. Sort diagonally/sort.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/08. Matrix/09. Sort diagonally/sort.cpp -------------------------------------------------------------------------------- /09. Hashing/01. Theory/theory.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/01. Theory/theory.md -------------------------------------------------------------------------------- /09. Hashing/02. Implementation/implement.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/02. Implementation/implement.cpp -------------------------------------------------------------------------------- /09. Hashing/03. Count distinct/count.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/03. Count distinct/count.cpp -------------------------------------------------------------------------------- /09. Hashing/04. Print freq/print.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/04. Print freq/print.cpp -------------------------------------------------------------------------------- /09. Hashing/05. Intersection/intersection.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/05. Intersection/intersection.cpp -------------------------------------------------------------------------------- /09. Hashing/06. Union/union.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/06. Union/union.cpp -------------------------------------------------------------------------------- /09. Hashing/07. Find pair/pair.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/07. Find pair/pair.cpp -------------------------------------------------------------------------------- /09. Hashing/08. Subarray sum 0/sum.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/08. Subarray sum 0/sum.cpp -------------------------------------------------------------------------------- /09. Hashing/09. Count subarray/count.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/09. Count subarray/count.cpp -------------------------------------------------------------------------------- /09. Hashing/10. Count 0 and 1/count.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/10. Count 0 and 1/count.cpp -------------------------------------------------------------------------------- /09. Hashing/11. Largest subarray/find.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/11. Largest subarray/find.cpp -------------------------------------------------------------------------------- /09. Hashing/12. Longest subsequence/longest.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/12. Longest subsequence/longest.cpp -------------------------------------------------------------------------------- /09. Hashing/13. Distinct elements/count.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/13. Distinct elements/count.cpp -------------------------------------------------------------------------------- /09. Hashing/14. More than NbyK/count.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/14. More than NbyK/count.cpp -------------------------------------------------------------------------------- /09. Hashing/15. Sort by freq/sort.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/15. Sort by freq/sort.cpp -------------------------------------------------------------------------------- /09. Hashing/16. winner/winner.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/16. winner/winner.cpp -------------------------------------------------------------------------------- /09. Hashing/17. Group Anagram/anagram.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/17. Group Anagram/anagram.cpp -------------------------------------------------------------------------------- /09. Hashing/18. Smaller Right/smaller.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/09. Hashing/18. Smaller Right/smaller.cpp -------------------------------------------------------------------------------- /10. Strings/01. Theory/theory.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/01. Theory/theory.md -------------------------------------------------------------------------------- /10. Strings/02. Operations/operations.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/02. Operations/operations.cpp -------------------------------------------------------------------------------- /10. Strings/03. Split and store/string.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/03. Split and store/string.cpp -------------------------------------------------------------------------------- /10. Strings/04. Letter frequency/freq.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/04. Letter frequency/freq.cpp -------------------------------------------------------------------------------- /10. Strings/05. Word frequency/freq.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/05. Word frequency/freq.cpp -------------------------------------------------------------------------------- /10. Strings/06. Palindrome/palindrome.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/06. Palindrome/palindrome.cpp -------------------------------------------------------------------------------- /10. Strings/07. Subsequence/checkSubsequence.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/07. Subsequence/checkSubsequence.cpp -------------------------------------------------------------------------------- /10. Strings/07. Subsequence/printSubsequence.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/07. Subsequence/printSubsequence.cpp -------------------------------------------------------------------------------- /10. Strings/08. Anagram/anagram.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/08. Anagram/anagram.cpp -------------------------------------------------------------------------------- /10. Strings/09. First Repeating/repeat.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/09. First Repeating/repeat.cpp -------------------------------------------------------------------------------- /10. Strings/10. First non-repeating/nonRepeating.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/10. First non-repeating/nonRepeating.cpp -------------------------------------------------------------------------------- /10. Strings/11. Reverse words/reverse.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/11. Reverse words/reverse.cpp -------------------------------------------------------------------------------- /10. Strings/12. Naive search/pattern.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/12. Naive search/pattern.cpp -------------------------------------------------------------------------------- /10. Strings/13. Improved Naive/search.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/13. Improved Naive/search.cpp -------------------------------------------------------------------------------- /10. Strings/14. Rabin Karp Algorithm/rk.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/14. Rabin Karp Algorithm/rk.cpp -------------------------------------------------------------------------------- /10. Strings/15. KMP algorithm/1_lps.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/15. KMP algorithm/1_lps.cpp -------------------------------------------------------------------------------- /10. Strings/15. KMP algorithm/kmp.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/15. KMP algorithm/kmp.cpp -------------------------------------------------------------------------------- /10. Strings/16. Check Rotated/check.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/16. Check Rotated/check.cpp -------------------------------------------------------------------------------- /10. Strings/17. Anagram search/search.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/17. Anagram search/search.cpp -------------------------------------------------------------------------------- /10. Strings/18. Lexicographic rank/rank.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/18. Lexicographic rank/rank.cpp -------------------------------------------------------------------------------- /10. Strings/19. Distinct characters/longest.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/19. Distinct characters/longest.cpp -------------------------------------------------------------------------------- /10. Strings/20. Pangram/pangram.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/20. Pangram/pangram.cpp -------------------------------------------------------------------------------- /10. Strings/21. LargestNumber/largest.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/21. LargestNumber/largest.cpp -------------------------------------------------------------------------------- /10. Strings/22. K distinctChar/kdistinct.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/10. Strings/22. K distinctChar/kdistinct.cpp -------------------------------------------------------------------------------- /11. Pointers/01. Introduction/1. Pointer.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/11. Pointers/01. Introduction/1. Pointer.md -------------------------------------------------------------------------------- /11. Pointers/01. Introduction/2. Double Pointer.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/11. Pointers/01. Introduction/2. Double Pointer.md -------------------------------------------------------------------------------- /11. Pointers/01. Introduction/pointer-to-pointer.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/11. Pointers/01. Introduction/pointer-to-pointer.webp -------------------------------------------------------------------------------- /11. Pointers/01. Introduction/pointers-in-c.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/11. Pointers/01. Introduction/pointers-in-c.png -------------------------------------------------------------------------------- /11. Pointers/02. Basics/pointer.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/11. Pointers/02. Basics/pointer.cpp -------------------------------------------------------------------------------- /11. Pointers/03 .swap/swap.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/11. Pointers/03 .swap/swap.cpp -------------------------------------------------------------------------------- /11. Pointers/04. Pointer to array/array.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/11. Pointers/04. Pointer to array/array.cpp -------------------------------------------------------------------------------- /11. Pointers/05. Pointer to structure/structure.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/11. Pointers/05. Pointer to structure/structure.cpp -------------------------------------------------------------------------------- /11. Pointers/06. Pointer to function/function.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/11. Pointers/06. Pointer to function/function.cpp -------------------------------------------------------------------------------- /11. Pointers/07. Pointer Arithmatic/arithmetic.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/11. Pointers/07. Pointer Arithmatic/arithmetic.cpp -------------------------------------------------------------------------------- /12. Linked List/01. Theory/linkedlist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/01. Theory/linkedlist.png -------------------------------------------------------------------------------- /12. Linked List/01. Theory/theory.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/01. Theory/theory.md -------------------------------------------------------------------------------- /12. Linked List/02. SLL/01. Singly Linked List/link.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/02. SLL/01. Singly Linked List/link.cpp -------------------------------------------------------------------------------- /12. Linked List/02. SLL/01. Singly Linked List/list.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/02. SLL/01. Singly Linked List/list.cpp -------------------------------------------------------------------------------- /12. Linked List/02. SLL/01. Singly Linked List/listlinked.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/02. SLL/01. Singly Linked List/listlinked.cpp -------------------------------------------------------------------------------- /12. Linked List/02. SLL/02. Traverse/traverse.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/02. SLL/02. Traverse/traverse.cpp -------------------------------------------------------------------------------- /12. Linked List/02. SLL/03. Insert begin/insert.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/02. SLL/03. Insert begin/insert.cpp -------------------------------------------------------------------------------- /12. Linked List/02. SLL/04. Insert end/insert.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/02. SLL/04. Insert end/insert.cpp -------------------------------------------------------------------------------- /12. Linked List/02. SLL/05. Delete head/delete.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/02. SLL/05. Delete head/delete.cpp -------------------------------------------------------------------------------- /12. Linked List/02. SLL/06. Delete tail/delete.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/02. SLL/06. Delete tail/delete.cpp -------------------------------------------------------------------------------- /12. Linked List/02. SLL/07. Insert at pos/insert.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/02. SLL/07. Insert at pos/insert.cpp -------------------------------------------------------------------------------- /12. Linked List/02. SLL/08. Search/search.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/02. SLL/08. Search/search.cpp -------------------------------------------------------------------------------- /12. Linked List/02. SLL/09. Reverse/reverse.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/02. SLL/09. Reverse/reverse.cpp -------------------------------------------------------------------------------- /12. Linked List/02. SLL/Master/list.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/02. SLL/Master/list.cpp -------------------------------------------------------------------------------- /12. Linked List/03 DLL/01. Doubly Linked List/doublyLL.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/03 DLL/01. Doubly Linked List/doublyLL.cpp -------------------------------------------------------------------------------- /12. Linked List/03 DLL/02. Insert begin/insert.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/03 DLL/02. Insert begin/insert.cpp -------------------------------------------------------------------------------- /12. Linked List/03 DLL/03. Insert end/insert.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/03 DLL/03. Insert end/insert.cpp -------------------------------------------------------------------------------- /12. Linked List/03 DLL/04. Delete head/delete.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/03 DLL/04. Delete head/delete.cpp -------------------------------------------------------------------------------- /12. Linked List/03 DLL/05. Delete tail/delete.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/03 DLL/05. Delete tail/delete.cpp -------------------------------------------------------------------------------- /12. Linked List/03 DLL/06. Insert at pos/insert.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/03 DLL/06. Insert at pos/insert.cpp -------------------------------------------------------------------------------- /12. Linked List/03 DLL/07 Reverse/revDoublyLL.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/03 DLL/07 Reverse/revDoublyLL.cpp -------------------------------------------------------------------------------- /12. Linked List/03 DLL/08. Search/search.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/03 DLL/08. Search/search.cpp -------------------------------------------------------------------------------- /12. Linked List/03 DLL/Master/list.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/03 DLL/Master/list.cpp -------------------------------------------------------------------------------- /12. Linked List/04. SCLL/01. Singly Circular LL/singlyCircular.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/04. SCLL/01. Singly Circular LL/singlyCircular.cpp -------------------------------------------------------------------------------- /12. Linked List/04. SCLL/02. Traverse/traverse.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/04. SCLL/02. Traverse/traverse.cpp -------------------------------------------------------------------------------- /12. Linked List/04. SCLL/03. Insert begin/insert.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/04. SCLL/03. Insert begin/insert.cpp -------------------------------------------------------------------------------- /12. Linked List/04. SCLL/04. Insert end/insert.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/04. SCLL/04. Insert end/insert.cpp -------------------------------------------------------------------------------- /12. Linked List/04. SCLL/05. Delete head/delete.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/04. SCLL/05. Delete head/delete.cpp -------------------------------------------------------------------------------- /12. Linked List/04. SCLL/06. Delete tail/delete.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/04. SCLL/06. Delete tail/delete.cpp -------------------------------------------------------------------------------- /12. Linked List/04. SCLL/07. Delete kth node/delete.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/04. SCLL/07. Delete kth node/delete.cpp -------------------------------------------------------------------------------- /12. Linked List/05. CDLL/01. Circular Doubly LL/cdll.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/05. CDLL/01. Circular Doubly LL/cdll.cpp -------------------------------------------------------------------------------- /12. Linked List/05. CDLL/02. Traverse/traverse.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/05. CDLL/02. Traverse/traverse.cpp -------------------------------------------------------------------------------- /12. Linked List/05. CDLL/03. Insert begin/insert.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/05. CDLL/03. Insert begin/insert.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/01. Sorted insert/sorted.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/01. Sorted insert/sorted.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/02. Middle item/center.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/02. Middle item/center.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/03. Nth from end/printnode.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/03. Nth from end/printnode.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/04. Reverse/reverse.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/04. Reverse/reverse.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/05. Remove dups/remove.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/05. Remove dups/remove.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/06. Reverse in group/rev.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/06. Reverse in group/rev.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/07. Detect loop/detect.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/07. Detect loop/detect.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/08. Cycle detection/floyd.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/08. Cycle detection/floyd.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/09. Remove loop/remove.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/09. Remove loop/remove.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/10. Segregate node/byIndex.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/10. Segregate node/byIndex.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/10. Segregate node/segregate.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/10. Segregate node/segregate.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/11. Intersection/common.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/11. Intersection/common.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/12. Pairwise swap/swap.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/12. Pairwise swap/swap.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/13. Random ptr/random.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/13. Random ptr/random.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/14. Merge/merge.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/14. Merge/merge.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/15. Palindrome/palindrome.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/15. Palindrome/palindrome.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/16. Add two number/add.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/16. Add two number/add.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/17. Rotate/rotate.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/17. Rotate/rotate.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/18. Merge Sort/mergesort.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/18. Merge Sort/mergesort.cpp -------------------------------------------------------------------------------- /12. Linked List/06. Questions/19. Reverse in range/revese.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/12. Linked List/06. Questions/19. Reverse in range/revese.cpp -------------------------------------------------------------------------------- /13. Stack/01. Theory/Theory.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/01. Theory/Theory.md -------------------------------------------------------------------------------- /13. Stack/02. Implementation/1_Array.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/02. Implementation/1_Array.cpp -------------------------------------------------------------------------------- /13. Stack/02. Implementation/2_Vector.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/02. Implementation/2_Vector.cpp -------------------------------------------------------------------------------- /13. Stack/02. Implementation/3_List.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/02. Implementation/3_List.cpp -------------------------------------------------------------------------------- /13. Stack/03. Balanced bracket/balanced.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/03. Balanced bracket/balanced.cpp -------------------------------------------------------------------------------- /13. Stack/04. Two stack/twoStack.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/04. Two stack/twoStack.cpp -------------------------------------------------------------------------------- /13. Stack/05. Stock span/span.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/05. Stock span/span.cpp -------------------------------------------------------------------------------- /13. Stack/06. Previous greater/prevMax.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/06. Previous greater/prevMax.cpp -------------------------------------------------------------------------------- /13. Stack/07. Next greater/nextMax.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/07. Next greater/nextMax.cpp -------------------------------------------------------------------------------- /13. Stack/08. Previous smaller/prevMin.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/08. Previous smaller/prevMin.cpp -------------------------------------------------------------------------------- /13. Stack/09. Next Smaller/nextMin.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/09. Next Smaller/nextMin.cpp -------------------------------------------------------------------------------- /13. Stack/10. Histogram area/_prerequisite.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/10. Histogram area/_prerequisite.cpp -------------------------------------------------------------------------------- /13. Stack/10. Histogram area/maxArea.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/10. Histogram area/maxArea.cpp -------------------------------------------------------------------------------- /13. Stack/11. Infix Prefix Posfix/Theory.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/13. Stack/11. Infix Prefix Posfix/Theory.md -------------------------------------------------------------------------------- /14. Queue/01. Theory/queue.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/14. Queue/01. Theory/queue.md -------------------------------------------------------------------------------- /14. Queue/02. Implementation/queueArr.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/14. Queue/02. Implementation/queueArr.cpp -------------------------------------------------------------------------------- /14. Queue/02. Implementation/queueList.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/14. Queue/02. Implementation/queueList.cpp -------------------------------------------------------------------------------- /14. Queue/03. Generate numbers/generate.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/14. Queue/03. Generate numbers/generate.cpp -------------------------------------------------------------------------------- /15. Deque/01. Theory/theory.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/15. Deque/01. Theory/theory.md -------------------------------------------------------------------------------- /15. Deque/02. Implementation/dequeArr.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/15. Deque/02. Implementation/dequeArr.cpp -------------------------------------------------------------------------------- /15. Deque/03. Max of subarrayK/max.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/15. Deque/03. Max of subarrayK/max.cpp -------------------------------------------------------------------------------- /16. Greedy/01. Theory/theory.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/16. Greedy/01. Theory/theory.md -------------------------------------------------------------------------------- /16. Greedy/02. Minimum Coins/minimum.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/16. Greedy/02. Minimum Coins/minimum.cpp -------------------------------------------------------------------------------- /16. Greedy/03. Activity selection/activity.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/16. Greedy/03. Activity selection/activity.cpp -------------------------------------------------------------------------------- /16. Greedy/04. Fractional Knapsack/knapsack.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/16. Greedy/04. Fractional Knapsack/knapsack.cpp -------------------------------------------------------------------------------- /16. Greedy/05. Job sequencing/job.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/16. Greedy/05. Job sequencing/job.cpp -------------------------------------------------------------------------------- /17. Tree/01. Theory/theory.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/01. Theory/theory.md -------------------------------------------------------------------------------- /17. Tree/02. Implementation/implement.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/02. Implementation/implement.cpp -------------------------------------------------------------------------------- /17. Tree/03. Traversal/traverse.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/03. Traversal/traverse.md -------------------------------------------------------------------------------- /17. Tree/04. Depth First Traversal/1_inorder_recursive.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/04. Depth First Traversal/1_inorder_recursive.cpp -------------------------------------------------------------------------------- /17. Tree/04. Depth First Traversal/2_inorder_iterative.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/04. Depth First Traversal/2_inorder_iterative.cpp -------------------------------------------------------------------------------- /17. Tree/04. Depth First Traversal/3_preorder_recursive.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/04. Depth First Traversal/3_preorder_recursive.cpp -------------------------------------------------------------------------------- /17. Tree/04. Depth First Traversal/4_preorder_iterative.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/04. Depth First Traversal/4_preorder_iterative.cpp -------------------------------------------------------------------------------- /17. Tree/04. Depth First Traversal/5_postorder_recursive.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/04. Depth First Traversal/5_postorder_recursive.cpp -------------------------------------------------------------------------------- /17. Tree/04. Depth First Traversal/6_postorder_iterative.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/04. Depth First Traversal/6_postorder_iterative.cpp -------------------------------------------------------------------------------- /17. Tree/05. Height/height.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/05. Height/height.cpp -------------------------------------------------------------------------------- /17. Tree/06. Print at K distance/print.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/06. Print at K distance/print.cpp -------------------------------------------------------------------------------- /17. Tree/07. Breadth First Traversal/1_usingtwoFunction.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/07. Breadth First Traversal/1_usingtwoFunction.cpp -------------------------------------------------------------------------------- /17. Tree/07. Breadth First Traversal/2_usingQueue.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/07. Breadth First Traversal/2_usingQueue.cpp -------------------------------------------------------------------------------- /17. Tree/07. Breadth First Traversal/3_NewLineWithNULL.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/07. Breadth First Traversal/3_NewLineWithNULL.cpp -------------------------------------------------------------------------------- /17. Tree/07. Breadth First Traversal/4_NewLineWithLoop.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/07. Breadth First Traversal/4_NewLineWithLoop.cpp -------------------------------------------------------------------------------- /17. Tree/08. Count Nodes/count.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/08. Count Nodes/count.cpp -------------------------------------------------------------------------------- /17. Tree/09. Maximum/max.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/09. Maximum/max.cpp -------------------------------------------------------------------------------- /17. Tree/10. Left View/left.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/10. Left View/left.cpp -------------------------------------------------------------------------------- /17. Tree/11 Right view/right.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/11 Right view/right.cpp -------------------------------------------------------------------------------- /17. Tree/12. Child Sum/sum.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/12. Child Sum/sum.cpp -------------------------------------------------------------------------------- /17. Tree/13. Height Balanced/balanced.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/13. Height Balanced/balanced.cpp -------------------------------------------------------------------------------- /17. Tree/14. Width/width.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/14. Width/width.cpp -------------------------------------------------------------------------------- /17. Tree/15. Convert to DLL/dll.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/15. Convert to DLL/dll.cpp -------------------------------------------------------------------------------- /17. Tree/16. Construct tree/construct.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/16. Construct tree/construct.cpp -------------------------------------------------------------------------------- /17. Tree/17. Snake Pattern/snake.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/17. Snake Pattern/snake.cpp -------------------------------------------------------------------------------- /17. Tree/18. Diameter/diameter.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/18. Diameter/diameter.cpp -------------------------------------------------------------------------------- /17. Tree/19. Compare/checkEqual.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/19. Compare/checkEqual.cpp -------------------------------------------------------------------------------- /17. Tree/20. Check Subtree/check.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/20. Check Subtree/check.cpp -------------------------------------------------------------------------------- /17. Tree/21. Count Subtree/count.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/21. Count Subtree/count.cpp -------------------------------------------------------------------------------- /17. Tree/22. Max Pathsum/maxpath.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/22. Max Pathsum/maxpath.cpp -------------------------------------------------------------------------------- /17. Tree/23. Mirror Tree/mirror.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/23. Mirror Tree/mirror.cpp -------------------------------------------------------------------------------- /17. Tree/24. Vertical width/width.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/24. Vertical width/width.cpp -------------------------------------------------------------------------------- /17. Tree/25. Connect Nodes/connect.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/25. Connect Nodes/connect.cpp -------------------------------------------------------------------------------- /17. Tree/26. List to Tree/tree.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/26. List to Tree/tree.cpp -------------------------------------------------------------------------------- /17. Tree/27. Foldable Tree/fold.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/27. Foldable Tree/fold.cpp -------------------------------------------------------------------------------- /17. Tree/28. Check CBT/check.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/28. Check CBT/check.cpp -------------------------------------------------------------------------------- /17. Tree/29. Diagonal Tree/diagonal.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/29. Diagonal Tree/diagonal.cpp -------------------------------------------------------------------------------- /17. Tree/30. Boundary/boundary.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/30. Boundary/boundary.cpp -------------------------------------------------------------------------------- /17. Tree/31. Built Tree/build.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/17. Tree/31. Built Tree/build.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/01. Theory/theory.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/01. Theory/theory.md -------------------------------------------------------------------------------- /18. Binary Search Tree/02. Implementation/implement.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/02. Implementation/implement.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/03. Search/search.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/03. Search/search.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/04. Insert/insert.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/04. Insert/insert.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/05. Delete/delete.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/05. Delete/delete.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/06. Floor/floor.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/06. Floor/floor.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/07. Ceil/ceil.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/07. Ceil/ceil.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/08. Range BST/range.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/08. Range BST/range.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/09. Range Count/range.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/09. Range Count/range.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/10. Pair Sum/pair.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/10. Pair Sum/pair.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/11. Vertical Traversal/vertical.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/11. Vertical Traversal/vertical.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/12. Veritcal Sum/vertical.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/12. Veritcal Sum/vertical.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/13. Top View/top.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/13. Top View/top.cpp -------------------------------------------------------------------------------- /18. Binary Search Tree/14. Bottom View/bottom.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/18. Binary Search Tree/14. Bottom View/bottom.cpp -------------------------------------------------------------------------------- /19. Graph/01. Theory/Graph.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/01. Theory/Graph.png -------------------------------------------------------------------------------- /19. Graph/01. Theory/theory.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/01. Theory/theory.md -------------------------------------------------------------------------------- /19. Graph/02. Implementation/graph_1_a.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/02. Implementation/graph_1_a.cpp -------------------------------------------------------------------------------- /19. Graph/02. Implementation/graph_1_a.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/02. Implementation/graph_1_a.png -------------------------------------------------------------------------------- /19. Graph/02. Implementation/graph_1_b.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/02. Implementation/graph_1_b.cpp -------------------------------------------------------------------------------- /19. Graph/02. Implementation/graph_1_b.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/02. Implementation/graph_1_b.png -------------------------------------------------------------------------------- /19. Graph/02. Implementation/graph_2_a.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/02. Implementation/graph_2_a.cpp -------------------------------------------------------------------------------- /19. Graph/02. Implementation/graph_2_a.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/02. Implementation/graph_2_a.png -------------------------------------------------------------------------------- /19. Graph/02. Implementation/graph_2_b.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/02. Implementation/graph_2_b.cpp -------------------------------------------------------------------------------- /19. Graph/02. Implementation/graph_2_b.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/02. Implementation/graph_2_b.png -------------------------------------------------------------------------------- /19. Graph/02. Implementation/graph_3.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/02. Implementation/graph_3.cpp -------------------------------------------------------------------------------- /19. Graph/03. DFS/01_dfs.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/03. DFS/01_dfs.cpp -------------------------------------------------------------------------------- /19. Graph/03. DFS/02_dfs.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/03. DFS/02_dfs.cpp -------------------------------------------------------------------------------- /19. Graph/03. DFS/03_dfs_itr.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/03. DFS/03_dfs_itr.cpp -------------------------------------------------------------------------------- /19. Graph/03. DFS/04_dfs_naray.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/03. DFS/04_dfs_naray.cpp -------------------------------------------------------------------------------- /19. Graph/04. Cond Comp/CC.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/04. Cond Comp/CC.cpp -------------------------------------------------------------------------------- /19. Graph/06. SSSP/01_sssp.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/06. SSSP/01_sssp.cpp -------------------------------------------------------------------------------- /19. Graph/06. SSSP/02_ques.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/06. SSSP/02_ques.cpp -------------------------------------------------------------------------------- /19. Graph/06. SSSP/03_ques.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/06. SSSP/03_ques.cpp -------------------------------------------------------------------------------- /19. Graph/07. Bipartite/01_bp.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/07. Bipartite/01_bp.cpp -------------------------------------------------------------------------------- /19. Graph/07. Bipartite/02_ques.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/07. Bipartite/02_ques.cpp -------------------------------------------------------------------------------- /19. Graph/08. Cycle Detection/01_findCycle.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/08. Cycle Detection/01_findCycle.cpp -------------------------------------------------------------------------------- /19. Graph/08. Cycle Detection/02_printCycle.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/08. Cycle Detection/02_printCycle.cpp -------------------------------------------------------------------------------- /19. Graph/08. Cycle Detection/03_directed.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/08. Cycle Detection/03_directed.cpp -------------------------------------------------------------------------------- /19. Graph/09. Problem/codechef.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/09. Problem/codechef.cpp -------------------------------------------------------------------------------- /19. Graph/10. InOut/inout.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/10. InOut/inout.cpp -------------------------------------------------------------------------------- /19. Graph/11. Diameter/ques.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/11. Diameter/ques.cpp -------------------------------------------------------------------------------- /19. Graph/12. Subtree Size/subtree.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/12. Subtree Size/subtree.cpp -------------------------------------------------------------------------------- /19. Graph/13. BFS/01_bfs.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/13. BFS/01_bfs.cpp -------------------------------------------------------------------------------- /19. Graph/13. BFS/02_bfs.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/13. BFS/02_bfs.cpp -------------------------------------------------------------------------------- /19. Graph/14. SSSP/sssp_bfs.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/14. SSSP/sssp_bfs.cpp -------------------------------------------------------------------------------- /19. Graph/15. Prime Path/prime.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/15. Prime Path/prime.cpp -------------------------------------------------------------------------------- /19. Graph/16. Feasible Relations/relations.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/16. Feasible Relations/relations.cpp -------------------------------------------------------------------------------- /19. Graph/17. Social Networking/social.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/17. Social Networking/social.cpp -------------------------------------------------------------------------------- /19. Graph/18. Word Ladder/word.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/18. Word Ladder/word.cpp -------------------------------------------------------------------------------- /19. Graph/19. Print paths/print.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/19. Print paths/print.cpp -------------------------------------------------------------------------------- /19. Graph/20. Bridges/01_bridges.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/20. Bridges/01_bridges.cpp -------------------------------------------------------------------------------- /19. Graph/20. Bridges/02_ques.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/20. Bridges/02_ques.cpp -------------------------------------------------------------------------------- /19. Graph/21. Articulation Points/cutVertices.cpp: -------------------------------------------------------------------------------- 1 | // TODO -------------------------------------------------------------------------------- /19. Graph/22. Topological Sort/01_bfstopo.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/22. Topological Sort/01_bfstopo.cpp -------------------------------------------------------------------------------- /19. Graph/22. Topological Sort/02_dfstopo.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/22. Topological Sort/02_dfstopo.cpp -------------------------------------------------------------------------------- /19. Graph/22. Topological Sort/03_ques.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/22. Topological Sort/03_ques.cpp -------------------------------------------------------------------------------- /19. Graph/22. Topological Sort/04_sssp_dag.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/22. Topological Sort/04_sssp_dag.cpp -------------------------------------------------------------------------------- /19. Graph/22. Topological Sort/05_cycle.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/22. Topological Sort/05_cycle.cpp -------------------------------------------------------------------------------- /19. Graph/23. DFS Grid/01_dfs.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/23. DFS Grid/01_dfs.cpp -------------------------------------------------------------------------------- /19. Graph/23. DFS Grid/02_dfs.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/23. DFS Grid/02_dfs.cpp -------------------------------------------------------------------------------- /19. Graph/24. Cond Comp/01_cc.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/24. Cond Comp/01_cc.cpp -------------------------------------------------------------------------------- /19. Graph/24. Cond Comp/02_cc.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/24. Cond Comp/02_cc.cpp -------------------------------------------------------------------------------- /19. Graph/25. BFS/01_bfs.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/25. BFS/01_bfs.cpp -------------------------------------------------------------------------------- /19. Graph/25. BFS/02_bfs.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/25. BFS/02_bfs.cpp -------------------------------------------------------------------------------- /19. Graph/25. BFS/03_bfs.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/25. BFS/03_bfs.cpp -------------------------------------------------------------------------------- /19. Graph/25. BFS/04_bfs.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/25. BFS/04_bfs.cpp -------------------------------------------------------------------------------- /19. Graph/26. Min Moves/knight.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/26. Min Moves/knight.cpp -------------------------------------------------------------------------------- /19. Graph/27. Kosaraju's Algo/kosaraju.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/27. Kosaraju's Algo/kosaraju.cpp -------------------------------------------------------------------------------- /19. Graph/28. Tarjan's Algo/tarjan.cpp: -------------------------------------------------------------------------------- 1 | // TODO -------------------------------------------------------------------------------- /19. Graph/29. Prim's algo/prim.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/29. Prim's algo/prim.cpp -------------------------------------------------------------------------------- /19. Graph/30. Kruskal's algo/dsu.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/30. Kruskal's algo/dsu.cpp -------------------------------------------------------------------------------- /19. Graph/30. Kruskal's algo/kruskal.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/19. Graph/30. Kruskal's algo/kruskal.cpp -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/README.md -------------------------------------------------------------------------------- /_Utility/01. Preprocessors/preprocessor.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/_Utility/01. Preprocessors/preprocessor.cpp -------------------------------------------------------------------------------- /_Utility/02. Builtin functions/builtInFn.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/_Utility/02. Builtin functions/builtInFn.cpp -------------------------------------------------------------------------------- /_Utility/03. vector/vector.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/_Utility/03. vector/vector.cpp -------------------------------------------------------------------------------- /_Utility/04. pair/pair.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/_Utility/04. pair/pair.cpp -------------------------------------------------------------------------------- /_Utility/05. set/set.c++: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/_Utility/05. set/set.c++ -------------------------------------------------------------------------------- /_Utility/06. map/map.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/_Utility/06. map/map.cpp -------------------------------------------------------------------------------- /_Utility/07. Strings/strings.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/_Utility/07. Strings/strings.cpp -------------------------------------------------------------------------------- /_Utility/08. List/list.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/_Utility/08. List/list.cpp -------------------------------------------------------------------------------- /_Utility/09. stack/stack.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/_Utility/09. stack/stack.cpp -------------------------------------------------------------------------------- /_Utility/_images/demo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nikhilsourav/Data-Structures-and-Algorithms/HEAD/_Utility/_images/demo.png --------------------------------------------------------------------------------