Open In App

SDE SHEET – A Complete Guide for SDE Preparation

Last Updated : 29 Mar, 2024
Improve
Improve
Like Article
Like
Save
Share
Report

What is SDE Sheet?

SDE Sheet is a curated list of the most popular questions among important topics, such as Data Structure and Algorithms (DSA), CS Subjects, Aptitude, etc, asked in the Software Development Engineer Interviews.
 

GFG SDE Sheet

    How is this SDE sheet different or better from others?

  • This sheet contains a wide range of coding questions from different Data Structures and Algorithms.
  • It covers all the segments round-wise like MCQs, DSA (Coding Questions), CS Subjects, Puzzles, System Design, Projects.
  • It is helpful for both – Freshers and Experienced.

Table of Contents/Roadmap

 
 

Build a Perfect Resume

The sole purpose of a resume is to make you land your dream job. It introduces your qualifications, skills, achievements, and everything regarding your expertise. It helps you land into your career. When you have a perfect resume, nothing can be a hindrance to the best job.
Create and Know how to build a perfect Resume – Free Resume Builder By GeeksforGeeks – Create Resume Online
 

Multiple Choice Questions (MCQs)

 

Data Structures and Algorithms

Keep a track of all the DSA problems mentioned below – Practice SDE Sheet
Check out the tutorial videos for all of the problems listed below – SDE Sheet Videos. We will continue to add videos on a daily basis.

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 View Solve Watch
Equilibrium point View Solve Watch
Sort an array of 0s, 1s and 2s View Solve Watch
Reverse array in groups View Solve Watch
Convert array into Zig-Zag fashion View Solve Watch
Rearrange array alternatively View Solve Watch
Missing number in array View Solve Watch
K-th element of two sorted Arrays View Solve Watch
Check if two arrays are equal or not View Solve Watch
Kadane’s Algorithm View Solve Watch
Subarray with given sum View Solve Watch
Trapping Rain Water View Solve Watch
Minimum Platforms View Solve Watch
Stock buy and sell View Solve Watch
Largest Number formed from an Array View Solve Watch
Largest subarray with 0 sum View Solve Watch
Swapping pairs make sum equal View Solve Watch

Searching and Sorting

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

Hashing

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

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 View Solve Watch
Spirally traversing a matrix View Solve Watch
Search in a row wise and column wise sorted matrix View Solve Watch
Print all palindromic paths from top left to bottom right in a matrix View Solve Watch
Find the row with maximum number of 1s View Solve Watch
Find median in row wise sorted matrix View Solve Watch
Check if all rows of a matrix are circular rotations of each other View Solve Watch

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 View Solve Watch
Reverse words in a given string View Solve Watch
Check if string is rotated by two places View Solve Watch
Roman Number to Integer View Solve Watch
Anagram View Solve Watch
Remove Duplicates View Solve Watch
Longest Distinct Characters in the string View Solve Watch
Implement Atoi View Solve Watch
Implement strstr View Solve Watch
Rabin Karp Algorithm View Solve Watch
KMP Algorithm View Solve Watch
Convert a Sentence into its equivalent mobile numeric keypad sequence. View Solve Watch
Longest Common Prefix View Solve Watch
Smallest window in a string containing all the characters of another string View Solve Watch
Uncommon characters View Solve Watch
Minimum indexed character View Solve Watch

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 View Solve Watch
Tower Of Hanoi View Solve Watch
Special Keyboard View Solve Watch
Permutations of a given string View Solve Watch
N-Queen Problem View Solve Watch
Solve the Sudoku View Solve Watch
Rat in a Maze Problem View Solve Watch
Word Boggle View Solve Watch
Generate IP Addresses View Solve Watch

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 View Solve Watch
Rightmost different bit View Solve Watch
Check whether K-th bit is set or not View Solve Watch
Toggle bits given range View Solve Watch
Set kth bit View Solve Watch
Power of 2 View Solve Watch
Bit Difference View Solve Watch
Rotate Bits View Solve Watch
Swap all odd and even bits View Solve Watch
Count total set bits View Solve Watch
Longest Consecutive 1’s View Solve Watch
Sparse Number View Solve Watch
Alone in a couple View Solve Watch
Maximum subset XOR View Solve Watch

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 View Solve Watch
Merge Overlapping Intervals View Solve Watch
Stock span problem View Solve Watch
Next larger element View Solve Watch
Largest Rectangular Area in a Histogram View Solve Watch
Queue using two Stacks View Solve Watch
Stack using two queues View Solve Watch
Get minimum element from stack View Solve Watch
LRU Cache View Solve Watch
Circular tour View Solve Watch
First non-repeating character in a stream View Solve Watch
Rotten Oranges View Solve Watch
Maximum of all subarrays of size k View Solve Watch

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 View Solve Watch
Reverse a Linked list View Solve Watch
Rotate a Linked List View Solve Watch
Reverse a Linked List in groups of given size View Solve Watch
Intersection point in Y shaped Linked lists View Solve Watch
Detect Loop in Linked list View Solve Watch
Remove loop in Linked List View Solve Watch
n’th node from end of Linked list View Solve Watch
Flattening a Linked List View Solve Watch
Merge two sorted Linked lists View Solve Watch
Pairwise swap of a Linked list View Solve Watch
Add two numbers represented by Linked lists View Solve Watch
Check if Linked List is Palindrome View Solve Watch
Implement Queue using Linked List View Solve Watch
Implement Stack using Linked List View Solve Watch
Given a Linked list of 0s, 1s and 2s, sort it View Solve Watch
Delete without head pointer View Solve Watch

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 View Solve Watch
Number of leaf nodes View Solve Watch
Check if given Binary Tree is Height Balanced or Not View Solve Watch
Write Code to Determine if Two Trees are Identical or Not View Solve Watch
Given a binary tree, check whether it is a mirror of itself View Solve Watch
Maximum Path Sum View Solve Watch
Print Left View of Binary Tree View Solve Watch
Print Bottom View of Binary Tree View Solve Watch
Print a Binary Tree in Vertical Order View Solve Watch
Diameter of a Binary Tree View Solve Watch
Level order traversal in spiral form View Solve Watch
Connect Nodes at Same Level View Solve Watch
Convert a given Binary Tree to Doubly Linked List View Solve Watch
Serialize and Deserialize a Binary Tree View Solve Watch

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 View Solve Watch
Lowest Common Ancestor in a BST View Solve Watch
Ceil in BST View Solve Watch
K-th Largest Element in BST View Solve Watch
Largest BST in Binary Tree View Solve Watch
Merge Two Balanced Binary Search Trees View Solve Watch
Sorted Array to Balanced BST View Solve Watch

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 View Solve Watch
N meetings in one room View Solve Watch
Coin Piles View Solve Watch
Maximize Toys View Solve Watch
Page Faults in LRU View Solve Watch
Largest number possible View Solve Watch
Minimize the heights View Solve Watch
Minimize the sum of product View Solve Watch
Huffman Decoding View Solve Watch
Minimum Spanning Tree View Solve Watch

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 View Solve Watch
Longest Common Substring View Solve Watch
Longest Increasing Subsequence View Solve Watch
Longest Common Subsequence View Solve Watch
0 – 1 Knapsack Problem View Solve Watch
Maximum sum increasing subsequence View Solve Watch
Minimum number of jumps View Solve Watch
Edit Distance View Solve Watch
Coin Change Problem View Solve Watch
Subset Sum Problem View Solve Watch
Longest Palindrome in a String View Solve Watch
Form a Palindrome View Solve Watch
Box Stacking View Solve Watch
Rod Cutting View Solve Watch
Min Cost Path View Solve Watch
Minimum sum partition View Solve Watch
Count number of ways to cover a distance View Solve Watch
Egg Dropping Puzzle View Solve Watch

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 View Solve Watch
Find median in a stream View Solve Watch
Operations on Binary Min Heap View Solve Watch
Rearrange characters View Solve Watch
Merge K sorted Linked lists View Solve Watch
Kth smallest element in a row-column wise sorted matrix View Solve Watch

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 View Solve Watch
Breadth First Traversal View Solve Watch
Detect cycle in undirected graph View Solve Watch
Detect cycle in a directed graph View Solve Watch
Topological sort View Solve Watch
Find the number of islands View Solve Watch
Implementing Dijkstra View Solve Watch
Minimum Swaps View Solve Watch
Strongly Connected Components View Solve Watch
Shortest Source to Destination Path View Solve Watch
Find whether path exist View Solve Watch
Minimum Cost Path View Solve Watch
Circle of Strings View Solve Watch
Floyd Warshall View Solve Watch
Alien Dictionary View View Watch
Snake and Ladder Problem View Solve Watch

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) View Solve Watch
Trie | (Delete) View Solve Watch
Print unique rows in a given Binary matrix View Solve Watch
Counting the number of words in a Trie View Solve Watch
Longest Common Prefix using Trie View Solve Watch
Auto-complete feature using Trie View Solve Watch
Boggle | Set 2 (Using Trie) View Solve Watch
Minimum XOR Value Pair View Solve Watch
Palindrome pair in an array of words (or strings) View Solve Watch

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, Links, 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:

 

Puzzles
Puzzles are one of the ways to check your problem-solving skills. These are tricky questions that let you think logically.
Try to solve these 20 most popular puzzles asked in Interviews
 
Projects
Thoroughly revise all the work you have done till now in your projects. The grilling about projects can sometimes be very deep. Also, choose your words before you speak. Mention only those topics where you think you are fine to be grilled upon.
If you haven’t made a project then take an idea from GFG Projects and start working on it.
 
System Design
System Design is the process of designing the architecture, components, and interfaces for a system so that it meets the end-user requirements. System Design for tech interviews is something that can’t be ignored!
Almost every IT giant whether it be Facebook, Amazon, Google, or any other ask various questions based on System Design concepts such as scalability, load-balancing, caching, etc. in the interview.

This specifically designed System Design tutorial will help you to learn and master System Design concepts in the most efficient way from basics to advanced level.

Note: We will start uploading videos soon.

Bonus SDE Sheets

You can prepare for several types of interviews here. For instance, if you want to prepare for a Google interview, we have an SDE sheet specifically designed for that purpose. Here we attached the links to the top 5 product based and top 5 Service based preparation SDE Sheets.

 



Like Article
Suggest improvement
Next
Share your thoughts in the comments

Similar Reads