Filter interviews by
Top trending discussions
There are multiple ways to achieve the target score in a game or competition.
Incrementing by 1 point each time until reaching the target score
Combining different point values to reach the target score
Using bonus points or multipliers to reach the target score
I was interviewed in Jan 2021.
Round duration - 90 minutes
Round difficulty - Hard
Online coding round , 2-3 questions. Level - med-hard
Identify if the provided integer 'N' is a Fibonacci number.
A number is termed as a Fibonacci number if it appears in the Fibonacci sequence, where each number is the sum of...
Check if a given number is a Fibonacci number or not.
Iterate through the Fibonacci sequence until you find a number greater than or equal to the given number.
Check if the given number matches the Fibonacci number found in the sequence.
If the given number matches, output 'YES'; otherwise, output 'NO'.
Your task is to break a board of given dimensions 'L' by 'W' into 'L' * 'W' smaller squares, ensuring the total cost of breaking is minimized.
The first line con...
Minimize cost of breaking a board into smaller squares by optimizing horizontal and vertical cuts.
Iterate through all possible horizontal and vertical cuts to find the minimum cost
Use dynamic programming to store and reuse subproblem solutions
Calculate the cost of breaking the board into smaller squares based on the given dimensions and cut costs
Round duration - 60 Minutes
Round difficulty - Medium
2 interviewers , coding problem, no compilation.
Ninja has started a social networking site called Ninjas Space. The platform consists of ‘N’ users and supports ‘M’ different languages. Users communicate if they know at...
Determine the minimum number of users to teach a common language so all friends can communicate on a social networking site.
Create a graph where users are nodes and friendships are edges.
Find connected components in the graph.
For each connected component, determine the minimum number of users to teach a common language.
Return the sum of minimum users needed for all connected components.
Round duration - 40 minutes
Round difficulty - Medium
CS fundamentals. Tough round. 40 mins interview. 1 interviewer from USA
Round duration - 40 minutes
Round difficulty - Hard
System Design Problem
Design a Facebook-like application for social networking.
User profiles with personal information and photos
News feed displaying posts from friends
Ability to like, comment, and share posts
Friend requests and messaging functionality
Groups and events for community engagement
Tip 1 : Never leave any topic from any chapter / Subject
Tip 2 : Learn to explain your thoughts well
Tip 3 : Learn from previous experiences / interviews / problems asked.
Tip 4 : Atleast 4 projects in Resume
Tip 1 : Atleast 4 projects on Resume
Tip 2 : Do not write false things. You always get caught. Be genuine.
I applied via Company Website and was interviewed in Nov 2024. There were 2 interview rounds.
Leetcode similar coding tests
DSA round was there it was good
I applied via LinkedIn and was interviewed in Jul 2024. There was 1 interview round.
I want to join Facebook because of its innovative technology, global impact, and opportunities for growth.
Innovative technology: Facebook is known for its cutting-edge technology and constant innovation.
Global impact: Working at Facebook would allow me to contribute to a platform that connects billions of people worldwide.
Opportunities for growth: Facebook offers a dynamic and fast-paced work environment with ample opp...
I appreciate the personalized news feed feature on Facebook.
Personalized news feed shows content based on user interests
Helps users stay updated on relevant information
Allows users to engage with content they are interested in
I was interviewed in Jul 2021.
Round duration - 90 minutes
Round difficulty - Hard
This was an online coding round where we had 2 questions to solve under 90 minutes . Both the questions were preety hard according to me . One has to have a fair share of knowledge in Data Structures and Algorithms to pass this round .
Given a matrix of non-negative integers of size 'N x M', where 'N' and 'M' denote the number of rows and columns respectively, find the length of t...
The task is to find the length of the longest increasing path in a 2D matrix, where you can move in four directions: left, right, up, or down from each cell.
Traverse the matrix and for each cell, find the longest increasing path starting from that cell
Use dynamic programming to store the length of the longest increasing path for each cell
Recursively explore all four directions from each cell, checking if the next cell ...
Ninja is adventurous and loves traveling while being mindful of his expenses. Given a set of 'N' stations connected by 'M' trains, each train starting from station 'A' and r...
The task is to find the cheapest price from the given source to destination with up to K stops.
Read the number of test cases
For each test case, read the number of stations and trains
Read the details of each train (source, destination, ticket price)
Read the source station, destination station, and maximum number of stops
Implement a graph data structure to represent the stations and trains
Use a modified version of Dijkst...
Round duration - 60 Minutes
Round difficulty - Medium
This Round was DS and Algo round and it started with formal introduction, followed by 2 problems. We first dicussed the
approach the time complexity and proper code covering all cases.
Given a binary tree where each node contains an integer value, and a value 'K', your task is to find all the paths in the binary tree such that the sum of the node values in ...
The task is to print every path of a binary tree with the sum of nodes in the path as 'K'.
Traverse the binary tree and keep track of the current path and its sum
At each node, check if the sum of the current path equals 'K'
If yes, add the current path to the result
Continue traversing the left and right subtrees recursively
Remove the current node from the path before backtracking
Given an array of distinct positive integers ARR
and a non-negative integer 'B', find all unique combinations in the array where the sum is equal to 'B'. Numbers can be c...
The task is to find all unique combinations in an array whose sum is equal to a given target sum.
Use backtracking to generate all possible combinations
Sort the array in non-decreasing order to ensure elements in each combination are in non-decreasing order
Start with an empty combination and iterate through the array, adding each element to the combination and recursively calling the function with the remaining sum
If th...
Round duration - 50 Minutes
Round difficulty - Medium
This Round was DS/Algo + Core round and it started with formal introduction, followed by 3 problems. We first dicussed
the approach the time complexity and proper code covering all cases for the 2 coding problems . The last question was
related to OS and was a bit theoretical .
Given a list ACCOUNTS
where each element consists of a list of strings, with the first element being the name of the account holder, and the subsequent elements being the email ad...
The task is to merge accounts belonging to the same person based on common emails and return the merged accounts.
Iterate through each account and create a mapping of emails to account holders
Iterate through the mapping and merge accounts with common emails
Sort the merged accounts and return the result
The goal is to construct a binary tree from given preorder and inorder traversal lists of the tree nodes.
preorder = [1, 2, ...
The task is to construct a binary tree using the given inorder and preorder traversals.
Use the preorder traversal to determine the root of the binary tree
Use the inorder traversal to determine the left and right subtrees of the root
Recursively construct the left and right subtrees
Return the root node of the constructed binary tree
Demand paging is a memory management technique where pages are loaded into memory only when needed.
Demand paging allows for efficient memory utilization by loading pages into memory on demand.
It reduces the amount of initial memory required to start a process.
When a page is needed but not in memory, a page fault occurs and the required page is loaded from disk.
Demand paging allows for larger virtual memory space than p...
Round duration - 60 minutes
Round difficulty - Medium
This was a preety intense round as I was grilled more on my System Design concepts but eventually I was able to
asnwers all the questions with some help from the interviewer.
General Tip : While preparing for Facebook Interviews , make sure you read and understand some of the most important features that Facebook incorporates like Graph Search , Adding a friend , Removing a friend , Storing Likes/Dislikes and so on.
All these features are important to learn because at their core they are nothing but Data Structures used and implemented very elegantly . So before your next Facebook interview , do read these topics and be confident about your LLD as well as HLD skills.
Facebook stores likes/dislikes using a combination of databases and caching systems.
Likes/dislikes are stored in a distributed database system like Cassandra or HBase.
Each like/dislike is associated with a user and the content being liked/disliked.
The database is sharded to handle the large volume of likes/dislikes.
Caching systems like Memcached or Redis are used to improve read performance.
Likes/dislikes can be stored...
Facebook implements graph search by indexing user connections and content to enable efficient search queries.
Facebook indexes user connections and content to build a graph database.
The graph database is used to store and retrieve information about users, their relationships, and their content.
Graph search queries are executed by traversing the graph database to find relevant connections and content.
Facebook uses variou...
Facebook Chat is a real-time messaging system that allows users to send and receive instant messages.
Facebook Chat uses a client-server architecture.
It utilizes long polling or WebSockets for real-time communication.
Messages are stored in a message queue for delivery.
Chat messages are encrypted for security.
Facebook Chat supports features like read receipts, typing indicators, and group chats.
Tip 1 : Must do Previously asked Interview as well as Online Test Questions.
Tip 2 : Go through all the previous interview experiences from Codestudio and Leetcode.
Tip 3 : Do at-least 2 good projects and you must know every bit of them.
Tip 1 : Have at-least 2 good projects explained in short with all important points covered.
Tip 2 : Every skill must be mentioned.
Tip 3 : Focus on skills, projects and experiences more.
Few aptitude questions were asked in the interview
Reverse string without doing anything to special characters
I was interviewed before Sep 2020.
Round duration - 90 minutes
Round difficulty - Easy
This was MCQ+Coding round.
Check if two strings are anagrams by comparing the sorted versions of the strings.
Sort both strings and compare if they are equal.
Use a hashmap to store the frequency of characters in each string and compare the maps.
Ignore spaces and punctuation when comparing the strings.
Round duration - 90 minutes
Round difficulty - Easy
This was face to face interview round.
Round duration - 90 minutes
Round difficulty - Easy
This was face to face interview round.
Tip 1 : Participate in live contests on websites like Codechef, Codeforces etc as much as possible.
Tip 2 : Practice previous interview questions from LeetCode, GeeksForGeeks.
Tip 3 : Revise Computer Science subjects like DBMS, OOPS thoroughly.
Add projects and Internships if you have done any and add only those things which you really know.
Final outcome of the interviewSelectedI was interviewed before Sep 2020.
Round duration - 90 Minutes
Round difficulty - Medium
Interview started at 11:00 am. It was an online round. During the coding round I submitted optimized solution and got full acceptance of the solutions.
You are provided with a directed graph composed of 'N' nodes. You have a matrix called 'EDGES' with dimensions M x 2, which specifies the 'M' edges in the graph. Each edge...
Detect cycle in a directed graph using depth-first search (DFS) algorithm.
Use DFS to traverse the graph and detect back edges indicating a cycle.
Maintain a visited array to keep track of visited nodes during traversal.
If a node is visited again during traversal and it is not the parent node, then a cycle exists.
Return true if a cycle is detected, false otherwise.
Round duration - 80 Minutes
Round difficulty - Medium
Interview started at 10:00 am. Interview went well, I was able to connect with the interviewer and enjoyed the whole interview
Find the next smallest palindrome strictly greater than a given number 'N' represented as a string 'S'.
You are given a number in string format, a...
Find the next smallest palindrome greater than a given number represented as a string.
Convert the string to an integer, find the next greater palindrome, and convert it back to a string.
Handle cases where the number is a palindrome or has all digits as '9'.
Consider both odd and even length numbers when finding the next palindrome.
Round duration - 80 Minutes
Round difficulty - Medium
Interview started at 11:00 am. Interview went well.
Given a binary tree of integers, your task is to return the boundary nodes of the tree in Anti-Clockwise direction starting from the root node.
The first line ...
Return the boundary nodes of a binary tree in Anti-Clockwise direction starting from the root node.
Traverse the left boundary nodes in a top-down manner
Traverse the leaf nodes from left to right
Traverse the right boundary nodes in a bottom-up manner
Handle cases where duplicates occur in the boundary nodes
Implement the function without printing as printing is already managed
Tip 1 : For Data Structures number of questions doesn't matter. Try to understand the logic behind them and try to apply them in creating multiple scenario's. Learn them by heart.
Tip 2 : For Web.Development Try to learn full stack development. See which part interests you more, Increase your knowledge horizon, Always try to build a system a system considering It will be served to millions of customers. By doing this 1-2 projects will increase and cover all the major things which one should learn in their career/college.
Tip 1 : Always try to make it a single page
Tip 2 : Always make resume company specific. eg. Data Structures part more if you are applying for MNC's eg. Amazon, Google, DE Shaw, browserstack.
based on 1 interview
Interview experience
AD Operations Specialist
18
salaries
| ₹0 L/yr - ₹0 L/yr |
Software Developer
12
salaries
| ₹0 L/yr - ₹0 L/yr |
Software Engineer
11
salaries
| ₹0 L/yr - ₹0 L/yr |
Technical Lead
11
salaries
| ₹0 L/yr - ₹0 L/yr |
Associate Manager
10
salaries
| ₹0 L/yr - ₹0 L/yr |
Microsoft Corporation
Amazon