SDE Sheet by Geeksforgeeks – Top Coding Interview Problems



SDE Sheet (Software Developer Coding Preparation) is a list of the most important topics or the most popular questions that are asked in the Software Development Engineer Interviews.
GFG SDE Sheet

How is this sheet different or better from others?
  • It doesn’t contain only coding questions.
  • It covers all the segments round-wise like MCQs, DSA (Coding Questions), CS Subjects, Puzzles, Design Pattern, Projects.
  • It is helpful for both – Freshers and Experienced.

Data Structures and Algorithms

Arrays
An array is a collection of items stored at contiguous memory locations. The idea is to store multiple items of the same type together.
Question Article Practice Video
Leaders in an array Link Link Link
Equilibrium point Link Link Link
Sort an array of 0s, 1s and 2s Link Link Link
Reverse array in groups Link Link Link
Convert array into Zig-Zag fashion Link Link Link
Rearrange array alternatively Link Link Link
Missing number in array Link Link Link
K-th element of two sorted Arrays Link Link Link
Check if two arrays are equal or not Link Link Link
Kadane’s Algorithm Link Link Link
Subarray with given sum Link Link Link
Trapping Rain Water Link Link Link
Minimum Platforms Link Link Link
Stock buy and sell Link Link Link
Largest Number formed from an Array Link Link Link
Largest subarray with 0 sum Link Link Link
Swapping pairs make sum equal Link Link Link

Searching and Sorting
Question Article Practice Video
Binary Search Link Link Link
Quick Sort Link Link Link
Merge Sort Link Link Link
Merge two sorted arrays Link Link Link
Inversion of Array Link Link Link
Search in a Rotated Array Link Link Link
Sorting Elements of an Array by Frequency Link Link Link
Sum of Middle Elements of two sorted arrays Link Link Link
K’th smallest element Link Link Link
Allocate minimum number of pages Link Link Link

Hashing
Question Article Practice Video
First element to occur k times Link Link Link
Find the element that appears once in sorted array Link Link Link
Number of pairs Link Link Link
Find all pairs with a given sum Link Link Link
Common elements Link Link Link
Find all four sum numbers Link Link Link
Count distinct elements in every window Link Link Link
Array Pair Sum Divisibility Problem Link Link Link
Longest consecutive subsequence Link Link Link
Array Subset of another array Link Link Link
Zero Sum Subarrays Link Link Link
Relative Sorting Link Link Link

Matrix
A matrix represents a collection of numbers arranged in an order of rows and columns. It is necessary to enclose the elements of a matrix in parentheses or brackets.
Question Article Practice Video
Rotate a matrix Link Link Link
Spirally traversing a matrix Link Link Link
Search in a row wise and column wise sorted matrix Link Link Link
Print all palindromic paths from top left to bottom right in a matrix Link Link Link
Find the row with maximum number of 1s Link Link Link
Find median in row wise sorted matrix Link Link Link
Check if all rows of a matrix are circular rotations of each other Link Link Link

String
Strings are defined as an array of characters. The difference between a character array and a string is the string is terminated with a special character ‘\0’.
Question Article Practice Video
Find first repeated character Link Link Link
Reverse words in a given string Link Link Link
Check if string is rotated by two places Link Link Link
Roman Number to Integer Link Link Link
Anagram Link Link Link
Remove Duplicates Link Link Link
Longest Distinct Characters in the string Link Link Link
Implement Atoi Link Link Link
Implement strstr Link Link Link
Rabin Karp Algorithm Link Link Link
KMP Algorithm Link Link Link
Convert a Sentence into its equivalent mobile numeric keypad sequence. Link Link Link
Longest Common Prefix Link Link Link
Smallest window in a string containing all the characters of another string Link Link Link
Uncommon characters Link Link Link
Minimum indexed character Link Link Link

Recursion and Backtracking

Recursion: The process in which a function calls itself directly or indirectly is called recursion and the corresponding function is called as recursive function.
Backtracking: Backtracking is an algorithmic-technique for solving problems recursively by trying to build a solution incrementally, one piece at a time, removing those solutions that fail to satisfy the constraints of the problem at any point of time (by time, here, is referred to the time elapsed till reaching any level of the search tree).
Question Article Practice Video
Recursively remove all adjacent duplicates Link Link Link
Tower Of Hanoi Link Link Link
Special Keyboard Link Link Link
Permutations of a given string Link Link Link
N-Queen Problem Link Link Link
Solve the Sudoku Link Link Link
Rat in a Maze Problem Link Link Link
Word Boggle Link Link Link
Generate IP Addresses Link Link Link

Bit Manipulation
Bit Manipulation is a technique used in a variety of problems to get the solution in an optimized way.
Question Article Practice Video
Find first set bit Link Link Link
Rightmost different bit Link Link Link
Check whether K-th bit is set or not Link Link Link
Toggle bits given range Link Link Link
Set kth bit Link Link Link
Power of 2 Link Link Link
Bit Difference Link Link Link
Rotate Bits Link Link Link
Swap all odd and even bits Link Link Link
Count total set bits Link Link Link
Longest Consecutive 1’s Link Link Link
Sparse Number Link Link Link
Alone in a couple Link Link Link
Maximum subset XOR Link Link Link

Stack and Queue

Stack: A stack is a linear data structure in which elements can be inserted and deleted only from one side of the list, called the top. A stack follows the LIFO (Last In First Out) principle.
Queue: A queue is a linear data structure in which elements can be inserted only from one side of the list called rear, and the elements can be deleted only from the other side called the front. The queue data structure follows the FIFO (First In First Out) principle.
Question Article Practice Video
Parenthesis Checker Link Link Link
Merge Overlapping Intervals Link Link Link
Stock span problem Link Link Link
Next larger element Link Link Link
Largest Rectangular Area in a Histogram Link Link Link
Queue using two Stacks Link Link Link
Stack using two queues Link Link Link
Get minimum element from stack Link Link Link
LRU Cache Link Link Link
Circular tour Link Link Link
First non-repeating character in a stream Link Link Link
Rotten Oranges Link Link Link
Maximum of all subarrays of size k Link Link Link

Linked List
A linked list is a linear data structure, in which the elements are not stored at contiguous memory locations.
Question Article Practice Video
Finding middle element in a linked list Link Link Link
Reverse a linked list Link Link Link
Rotate a Linked List Link Link Link
Reverse a Linked List in groups of given size Link Link Link
Intersection point in Y shaped linked lists Link Link Link
Detect Loop in linked list Link Link Link
Remove loop in Linked List Link Link Link
n’th node from end of linked list Link Link Link
Flattening a Linked List Link Link Link
Merge two sorted linked lists Link Link Link
Pairwise swap of a linked list Link Link Link
Add two numbers represented by linked lists Link Link Link
Check if Linked List is Palindrome Link Link Link
Implement Queue using Linked List Link Link Link
Implement Stack using Linked List Link Link Link
Given a linked list of 0s, 1s and 2s, sort it Link Link Link
Delete without head pointer Link Link Link

Binary Tree
A tree whose elements have at most 2 children is called a binary tree. Since each element in a binary tree can have only 2 children, we typically name them the left and right child.
Question Article Practice Video
Height of Binary Tree Link Link Link
Number of leaf nodes Link Link Link
Check if given Binary Tree is Height Balanced or Not Link Link Link
Write Code to Determine if Two Trees are Identical or Not Link Link Link
Given a binary tree, check whether it is a mirror of itself Link Link Link
Maximum Path Sum Link Link Link
Print Left View of Binary Tree Link Link Link
Print Bottom View of Binary Tree Link Link Link
Print a Binary Tree in Vertical Order Link Link Link
Diameter of a Binary Tree Link Link Link
Level order traversal in spiral form Link Link Link
Connect Nodes at Same Level Link Link Link
Convert a given Binary Tree to Doubly Linked List Link Link Link
Serialize and Deserialize a Binary Tree Link Link Link

Binary Search Tree
Binary Search Tree is a node-based binary tree data structure which has the following properties:
  • The left subtree of a node contains only nodes with keys lesser than the node’s key.
  • The right subtree of a node contains only nodes with keys greater than the node’s key.
  • The left and right subtree each must also be a binary search tree.
Question Article Practice Video
Check for BST Link Link Link
Lowest Common Ancestor in a BST Link Link Link
Ceil in BST Link Link Link
K-th Largest Element in BST Link Link Link
Largest BST in Binary Tree Link Link Link
Merge Two Balanced Binary Search Trees Link Link Link
Sorted Array to Balanced BST Link Link Link

Greedy Approach
Greedy is an algorithmic paradigm that builds up a solution piece by piece, always choosing the next piece that offers the most obvious and immediate benefit.
Question Article Practice Video
Activity Selection Link Link Link
N meetings in one room Link Link Link
Coin Piles Link Link Link
Maximize Toys Link Link Link
Page Faults in LRU Link Link Link
Largest number possible Link Link Link
Minimize the heights Link Link Link
Minimize the sum of product Link Link Link
Huffman Decoding Link Link Link
Minimum Spanning Tree Link Link Link

Dynamic Programming
Dynamic Programming is mainly an optimization over plain recursion. Wherever we see a recursive solution that has repeated calls for same inputs, we can optimize it using Dynamic Programming.
Question Article Practice Video
Minimum number of Coins Link Link Link
Longest Common Substring Link Link Link
Longest Increasing Subsequence Link Link Link
Longest Common Subsequence Link Link Link
0 – 1 Knapsack Problem Link Link Link
Maximum sum increasing subsequence Link Link Link
Minimum number of jumps Link Link Link
Edit Distance Link Link Link
Coin Change Problem Link Link Link
Subset Sum Problem Link Link Link
Longest Palindrome in a String Link Link Link
Form a Palindrome Link Link Link
Box Stacking Link Link Link
Rod Cutting Link Link Link
Min Cost Path Link Link Link
Minimum sum partition Link Link Link
Count number of ways to cover a distance Link Link Link
Egg Dropping Puzzle Link Link Link

Heap
A Heap is a special Tree-based data structure in which the tree is a complete binary tree.
Question Article Practice Video
Heap Sort Link Link Link
Find median in a stream Link Link Link
Operations on Binary Min Heap Link Link Link
Rearrange characters Link Link Link
Merge K sorted linked lists Link Link Link
Kth smallest element in a row-column wise sorted matrix Link Link Link

Graph
A Graph is a non-linear data structure consisting of nodes and edges. The nodes are sometimes also referred to as vertices and the edges are lines or arcs that connect any two nodes in the graph.
Question Article Practice Video
Depth First Traversal Link Link Link
Breadth First Traversal Link Link Link
Detect cycle in undirected graph Link Link Link
Detect cycle in a directed graph Link Link Link
Topological sort Link Link Link
Find the number of islands Link Link Link
Implementing Dijkstra Link Link Link
Minimum Swaps Link Link Link
Strongly Connected Components Link Link Link
Shortest Source to Destination Path Link Link Link
Find whether path exist Link Link Link
Minimum Cost Path Link Link Link
Circle of Strings Link Link Link
Floyd Warshall Link Link Link
Alien Dictionary Link Link Link
Snake and Ladder Problem Link Link Link

Trie
Trie is an efficient information retrieval data structure. Using Trie, search complexities can be brought to optimal limit (key length).
Question Article Practice Video
Trie | (Insert and Search) Link Link Link
Trie | (Delete) Link Link Link
Print unique rows in a given Binary matrix Link Link Link
Counting the number of words in a Trie Link Link Link
Longest Common Prefix using Trie Link Link Link
Auto-complete feature using Trie Link Link Link
Boggle | Set 2 (Using Trie) Link Link Link
Minimum XOR Value Pair Link Link Link
Palindrome pair in an array of words (or strings) Link Link Link

Operating System
An operating system acts as an intermediary between the user of a computer and computer hardware. The purpose of an operating system is to provide an environment in which a user can execute programs conveniently and efficiently.
Below links contains complete Operating System Study Material:

 

DBMS
Database is a collection of inter-related data which helps in efficient retrieval, insertion and deletion of data from database and organizes the data in the form of tables, views, schemas, reports etc.
Below links contains complete DBMS study Material:

 

SQL
SQL stands for Structured Query Language. It is a language used to interact with the database, i.e to create a database, to create a table in the database, to retrieve data or update a table in the database.
Below links contains complete SQL study Material:

 

Computer Networks
A computer network is a system that connects numerous independent computers in order to share information (data) and resources. The integration of computers and other different devices allows users to communicate more easily.
Below links contains complete Computer Networks study Material:

Last Updated on March 12, 2022 by admin

Tags:

Leave a Reply

Your email address will not be published. Required fields are marked *

Recommended Blogs