Skip to content

Solving problems and learning the use of different data structures and algorithms. It makes us capable to decide which algorithm works best in different scenarios and to understand the trade-offs between one data structure over the other.

Notifications You must be signed in to change notification settings

sunny0910/Data-Structures-Algorithms

Repository files navigation

Data-Structures-Algorithms

The Topics and Algorithms covered in this repository are as follows, followed by the link to GeekforGeeks reference in the brackets:

  • Sorting Algorithms

  • Trees

    • Basic operations (Insert, delete) (link)
    • BFS (in-order, pre-order, post-order) (link)
    • DFS (Level order) (link)
    • Left view (link)
    • Right view (link)
    • Top view (link)
    • Bottom view (link)
    • Bottom-Right view (link)
    • Boundary leaves traversal (link)
    • Zig-zak traversal (link)
    • Spiral traversal (link)
    • Check if Sum tree(link)
    • Check if Binary Search Tree (link
    • Nodes at distance K, distance between nodes (link)
    • Lowest common ancestor(LCS) in BST and Btree (link)
    • Is symmetric or mirror tree(link)
    • Tree from in-order and pre-order (link)
    • Tree from in-order and post-order(link)
    • BST to DLL (link)
    • Btree to DLL (link)
  • Linked Lists

    • Singly Linked List
      • Basic operations(Insert, delete, middle) (link)
      • Reverse, K-nodes reverse (Iterative, recursive) (link)
      • Incremental K-node reverse
      • Check LL is palindrome (link)
      • Dutch national flag problem(separate 0's, 1's, 2's) (link)
      • Add two number represented in linked lists (link)
      • Merge sort on SLL (link)
      • Detect and remove loop in linked list (link)
      • Decimal equivalent of binary linked list (link)
    • Doubly Linked List
      • Basic operations(Insert, delete, middle) (link)
      • Reverse DLL (link)
      • Merge sort on DLL (link)
    • Circular Linked List
      • Basic operations(Insert, delete, traverse) (link)
      • Middle of CLL
      • Reverse CLL
      • Merge-sort on CLL
  • Heaps

    • Min heap implementation (link)
    • Max heap implementation (link)
    • Kth min/max in array (link)
    • Sort almost sorted array (link)
    • Merge K sorted arrays (link)
    • Kth largest/smallest element in stream (link)
    • Median in stream using two heaps (link)
  • Stacks & queues

    • Rotten tomatoes problem (link)
    • Check for balanced parenthesis (link)
    • Next greater element in the array (link)
    • Next smaller element in the array (link)
    • Implementing K queues in one array (link)
    • Implementing K stacks in one array (link)
    • Minimum bracket reversal to balance expression (link)
    • Implement two stacks in one array (link)
  • Matrix

    • Boolean Matrix (link)
    • Min/Max cost path in Matrix (link)
    • Matrix path exists (link)
    • Rotate matrix by 90 degrees (link)
    • Spiral traversal of Matrix (link)
  • Arrays

    • Chocolate distribution problem (link)
    • Sliding window problem (link)
    • Rain water trapping problem (link)
    • Search in sorted & rotated array (link)
    • Bus/Train railway platform problem (link)
    • Stocks Buy & Sell problem (link)
    • Non repeating character in stream (link)
  • Strings

    • Largest number smaller than N with same digits (link)
    • Longest common substring in two strings (link)
    • Longest palindromic sub-sequence in one string (link)
    • Word break problem (link)
  • Tries

    • Basic operations (Insert, Search, Display all) (link)

About

Solving problems and learning the use of different data structures and algorithms. It makes us capable to decide which algorithm works best in different scenarios and to understand the trade-offs between one data structure over the other.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages