Skip to content

MvMukesh/DSAinPython-ForDataRoles

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Basics to Approches and Problem-Solving

GitHub Issues GitHub followers GitHub forks GitHub stars


Playlist Image

Problem Count Topic Level Problem Solution Notes Time R - 1 R - 2 R - 3
Linked List
1 - Easy LeetCode Reverse Linked List updating notes... ❌
2 - Medium LeetCode Add two numbers updating notes... ❌
3 - Medium LeetCode Remove Nth Node From End of List updating notes... ❌


Playlist Image


Data Structures Implementation - `Videos`

Advanced Data Structures

  • Disjoint Set (Union-Find)
    • Quick-find
    • Quick-union
    • Union by rank
    • Path compression
  • Bloom Filters
    • Standard Bloom filter
    • Counting Bloom filter
  • Skip Lists
    • Standard skip list
  • Suffix Arrays
    • Standard suffix array
  • Sparse Tables
    • Standard sparse table

Specialized Data Structures

  • Trie Variants
    • Patricia trie
    • Suffix tree
  • Spatial Data Structures
    • R-tree
    • R*-tree
    • k-d tree
    • Quad tree
  • Multidimensional Data Structures
    • Range tree
    • Interval tree
  • Persistent Data Structures
    • Persistent array
    • Persistent list
    • Persistent tree
Click Here: (Data Structures Time & Space Complexity)
ds_Time-Space cheet

Algorithms Implementation

  • Sorting
    • Binary
    • Selection
    • Insertion
    • Quick
    • Merge
    • Counting
    • Radix
    • Bucket
    • Heap
  • Search
    • Binary Search
    • Lower Bound
    • Upper Bound
    • Binary Search on Ranges
  • String
    • Rabin Karp
Click Here: Algorithms Time & Space Complexity)
algo_Time-Space Cheet

Patterns & Hacks

Pattern 1: Given input is a sorted (array, list or matrix)
            Use a variation of:
                1. Binary Search or
                2. Two Pointer strategy
Pattern 2: If asked minimum/maximum/top/closest'k' elements among 'n' elements
            Use:
                1. Heap
Pattern 3: If required to try all Permutations or Combinations of a input
            Use either:
                1. Recursive _ Backtracking or
                2. Iterative _ Breadth-First Search
Pattern 4: If required to solve Trees or Graph problems
            Use either:
                1. Breadth-First Search or
                2. Depth-First Search
Pattern 5: If given a Set of Strings among that we have to find some Common Substring 
             Use either:
                1. HashMap or
                2. Trie
Hack 1: Try to convert Recursive Solution to Iterative Solution
            Use Stack
Hack 2: If given problem have a Brute-Force solution in O(n^2)Time and O(1)Space, Try to find out for other Two Solutions 
             Use either:
                1. Map or Set for O(n)Time and O(n)Space
                2. Sorting for O(n log n)Time and O(1)Space
Hack 3: If given problem is to Optimize something, (say Maximization or Minimization)
             Use:
                1. Dynamic Programming
Hack 4: If given Bunch of Strings and asked to search something 
             Use either:
                1. HashMap or
                2. Trie
Hack 5: If given problem is LinkedList one, and ExtraSpace is not allowed  
             Use:
                1. Fast & Slow Pointer approach

Coding Interview Patterns

Patterns

Intension of analysis.png

  • Two Pointers
    • Fast and Slow Pointers
  • In-place reversal of Linked List
  • Sliding Window
  • Island Matrix Traversal
  • Merge Intervals
  • Cyclic Sort
  • Tree: Breadth First Search
  • Tree: Depth First Search
  • Two Heaps
  • Subsets
  • Modified Binary Search
  • Bitwise XOR
  • Top K Element
  • K-way merge
  • Backtracking
  • 0-1 Knapsack (DP)
  • Topological Sort (Graph)
  • Multi-threaded

Dynamic Programming Patterns

Patterns

  • Knapsack
  • Unbounded Knapsack
  • Fibonacci Numbers
  • Palindromic Subsequence
  • Longest Common Substring

System Design

Reference : List of Questions asked on System Design



Study Approach

  • Practice and Study consistently. No Streak breaks
  • Create Flashcards daily.
  • List down all the aha moments in one file.
  • Practice Java / Create Projects in JAVA
  • Reserve time for writing notes and practicing flashcards

Tests

$ poetry install
$ poetry run pytest --benchmark-skip

If you don't use poetry, there is also a classic requirements.txt file. to be updated...

Bugs

If you find any bug or incorrect implementation in this repo, please let me know by opening an issue or pull request. Data community would appreciate your help since they provide some random strings which are used in two of test cases.

Also Refer

About

Collection of everything DSA in Python specially for cracking Data | AI related roles

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages