This is a personal practice repository that I have created for the SDE practice problems. Any viewer is most welcomed to check out and get help.
Credits for the problem selection to the "Raj Vikramaditya" and a huge thanks to him and his youtube channel "take U forward"
Find the duplicate in an array of N integers. Sort an array of 0’s 1’s 2’s without using extra space or sorting algo Repeat and Missing Number Merge two sorted Arrays without extra space Kadane’s Algorithm Merge Overlapping Subintervals
Set Matrix Zeros Pascal Triangle Next Permutation Inversion of Array (Using Merge Sort) Stock Buy and Sell Rotate Matrix
Excel Column Number Find n^x in log N Count trailing zeros in factorial of a number Find GCD in Log NGrid Unique Paths Go through Puzzles from GFG (Search on own)
2 Sum problem 4 Sum problem Longest Consecutive Sequence Longest Subarray with 0 sum Count number of subarrays with given XOR(this clears a lot of problems) Longest substring without repeat
Reverse a LinkedList Find middle of LinkedList Merge two sorted Linked List Remove N-th node from back of LinkedList Delete a given Node when a node is given. (0(1) solution) Add two numbers as LinkedList
Find intersection point of Y LinkedListCheck if a LinkedList is palindrome or not. Reverse a LinkedList in groups. Detect a cycle and removing loop(two different questions and same concept) Flattening of a LinkedList Rotate a LinkedList Clone a Linked List with random and next pointer.
Merge two sorted LinkedLists Find the starting point of the loop. 3 sum Trapping rainwater Remove Duplicate from Sorted array Max continuous number of 1’s
N meeting in one room Activity Selection Greedy algorithm to find minimum number of coins Fractional Knapsack Problem Minimum number of platforms required for a railwayJob sequencing Problem
N queens Problem Sudoko M coloring Problem Rat in a Maze Print all Permutations of a string/array Word Break (print all ways)
Combination sum-1 Combination sum-2 Palindrome Partioning Subset Sum-1 Subset Sum-2 K-th permutation Sequence
1/N-th root of an integer (use binary search) (square root, cube root, ..) Matrix MedianFind the element that appears once in sorted array, and rest element appears twice (Binary search) Search element in a sorted and rotated array. K-th element of two sorted arrays Media of an array
you have time left, someone might ask) Check if a number if a power of 2 or not in O(1) Count total set bits Divide Integers without / operator Power Set (this is very important) Find MSB in o(1) Find square of a number without using multiplication or division operators.
Implement Stack / Implement Queue BFS Implement Stack using Queue Implement Queue using Stack Check for balanced parenthesesNext Greater Element
Next Smaller Element LRU cache (vvvv. imp) Largest rectangle in histogram Sliding Window maximum Implement Min Stack Rotten Orange (Using BFS)
Reverse Words in a String Longest Palindrome in a string Roman Number to Integer and vice versa Implement ATOI/STRSTR Longest Common Prefix Rabin Karp
Prefix Function/Z-Function KMP algo Minimum characters needed to be inserted in the beginning to make itpalindromic. Check for Anagrams Count and Say Compare version numbers
Inorder Traversal (with recursion and without recursion) Preorder Traversal (with recursion and without recursion) Postorder Traversal (with recursion and without recursion) LeftView Of Binary Tree Bottom View of Binary Tree Top View of Binary Tree
Level order Traversal / Level order traversal in spiral form Height of a Binary Tree Diameter of Binary Tree Check if Binary tree is height balanced or not LCA in Binary Tree Check if two trees are identical or not
Construct Binary Tree from inorder and preorder Construct Binary Tree from Inorder and Postorder Symmetric Binary Tree Flatten Binary Tree to LinkedList Check if Binary Tree is mirror of itself or not
Populate Next Right pointers of Tree Search given Key in BST Construct BST from given keys. Check is a BT is BST or not Find LCA of two nodes in BST Find the inorder predecessor/successor of a given Key in BST.
Floor and Ceil in a BST Find K-th smallest and K-th largest element in BST (2 different Questions) Find a pair with a given sum in BST BST iterator Size of the largest BST in a Binary TreeSerialize and deserialize Binary Tree
Binary Tree to Double Linked List Find median in a stream of running integers. K-th largest element in a stream. Distinct numbers in Window. K-th largest element in an unsorted array. Flood-fill Algorithm
Clone a graph (Not that easy as it looks) DFS BFS Detect A cycle in Undirected Graph/Directed Graph Topo Sort Number of islands (Do in Grid and Graph both) Bipartite Check
SCC(using KosaRaju’s algo) Djisktra’s AlgorithmBellman Ford Algo Floyd Warshall Algorithm MST using Prim’s Algo MST using Kruskal’s Algo
Max Product Subarray Longest Increasing Subsequence Longest Common Subsequence 0-1 Knapsack Edit Distance Maximum sum increasing subsequence Matrix Chain Multiplication
Maximum sum path in matrix, (count paths, and similar type do, also backtrack to find the maximum path) Coin change Subset Sum Rod Cutting Egg Dropping Word BreakPalindrome Partitioning (MCM Variation)
Revise OS notes that you would have made during your sem If not made notes, spend 2 or 3 days and make notes from Knowledge Gate.
Revise DBMS notes that you would have made during your semesters. If not made notes, spend 2 or 3 days and make notes from Knowledge Gate.
Revise CN notes, that you would have made during your sem. If not made notes, spend 2 or 3 days and make notes from Knowledge Gate.
Make a note of how will your represent your projects, and prepare all questions related to tech which you have used in your projects. Prepare a note which you can say for 3-10 minutes when he asks you that say something about the project.Hurrah!! You are ready for your placement after a month of hard-work without a cheat day.