Proud winner of ABECA 2024 - AmbitionBox Employee Choice Awards
Filter interviews by
Dsa mostly from arrays,trees.
posted on 6 Oct 2024
Asked single que which is dp
Topics : Trees, graphs
What people are saying about Google
I applied via LinkedIn and was interviewed in Jul 2023. There were 2 interview rounds.
Google interview questions for designations
I applied via Approached by Company and was interviewed before Jun 2023. There were 2 interview rounds.
Two coding questions to be done
Get interview-ready with Top Google Interview Questions
I applied via Approached by Company and was interviewed before Jan 2023. There were 3 interview rounds.
Swap two numbers with any of the language
Discuss about your family members
A software intern developer is a student or recent graduate who works on software development projects under the guidance of experienced developers.
Assists in coding, testing, and debugging software applications
Learns new programming languages and technologies
Participates in team meetings and contributes to project discussions
I appeared for an interview before May 2023.
Array string questions
I appeared for an interview in Feb 2021.
Round duration - 60 minutes
Round difficulty - Easy
Given 'N' subjects, each containing a certain number of problems, and 'K' friends, assign subjects to friends such that each subject goes to exactly one friend, maintain...
Assign subjects to friends to minimize maximum workload, find minimum time for most loaded friend.
Sort subjects in descending order
Assign subjects to friends one by one until all subjects are assigned
The maximum workload will be the sum of problems assigned to the friend with the most problems
Return the maximum workload as the minimum time required
Given an array of integers, determine the sum of bit differences among all possible pairs that can be formed using the elements of the array.
The b...
Calculate sum of bit differences among all pairs in an array of integers.
Iterate through all pairs of elements in the array
Convert each pair of elements to binary representation
Count the differing bits in the binary representations
Sum up the differing bits for all pairs to get the final result
Round duration - 60 minutes
Round difficulty - Medium
Given an integer 'N', calculate and print the sum of the least common multiples (LCM) for each integer from 1 to N with N.
The sum is represented as:LCM(1, N) + LCM(2, N) + ....
Calculate and print the sum of least common multiples (LCM) for each integer from 1 to N with N.
Iterate from 1 to N and calculate LCM of each number with N
Sum up all the calculated LCMs to get the final result
Implement a function to calculate LCM of two numbers
Given a 9x9 Sudoku board, your task is to fill the empty slots and return the completed Sudoku solution.
A Sudoku is a grid composed of nine 3x3 smaller grids. The challenge is to fill in the...
Implement a Sudoku solver for a 9x9 grid with constraints on row, column, and 3x3 grid.
Create a recursive function to solve the Sudoku puzzle by trying out different numbers in empty slots.
Use backtracking to backtrack and try different numbers if a conflict is encountered.
Ensure each number appears only once in each row, column, and 3x3 grid.
Implement a function to check if a number can be placed in a particular posit...
Round duration - 60 minutes
Round difficulty - Hard
Given a singly linked list of integers and a reference to a node, your task is to delete that specific node from the linked list. Each node in the linked li...
Given a singly linked list of integers and a reference to a node, delete the specified node from the linked list.
Traverse the linked list to find the node to be deleted.
Update the pointers to skip over the node to be deleted.
Print the modified linked list after deletion.
Ensure the node to be deleted is not the tail node.
Round duration - 60 Minutes
Round difficulty - Easy
Timing was around 3 pm.
Given an array ARR
consisting of N
integers, your goal is to determine the maximum possible sum of a non-empty contiguous subarray within this array.
Find the maximum sum of a contiguous subarray within an array of integers.
Use Kadane's algorithm to find the maximum subarray sum efficiently.
Initialize two variables: maxEndingHere and maxSoFar.
Iterate through the array and update the variables accordingly.
Return the maxSoFar as the result.
Tip 1 : Practice on white board
Tip 2 : Spend daily some time
Tip 3 : Practice previous questions
Tip 1 : Resume should be short and neat
Tip 2 : Keep only thing in which you are sure you will answer all questions
I appeared for an interview in Feb 2021.
Round duration - 30 minutes
Round difficulty - Medium
This round was to test if Google should spend time in interviewing me or not. I was asked around 8 questions that any coder must know, like time complexities of various algorithms, basic understanding of trees and graphs, some concepts specific to the chosen language etc. Apart from these, there was a question to test my mental arithmetic that can be important for system design interviews.
This round went pretty well for me and I moved to the next Round.
Given a binary tree with N
nodes, determine whether the tree is a Binary Search Tree (BST). If it is a BST, return true
; otherwise, return false
.
A binary search tree (BST)...
Validate if a binary tree is a Binary Search Tree (BST) based on given properties.
Check if the left subtree of a node contains only nodes with data less than the node's data.
Verify if the right subtree of a node contains only nodes with data greater than the node's data.
Ensure that both the left and right subtrees are also binary search trees.
Traverse the tree in level order form to validate the BST properties.
Return t...
Round duration - 45 minutes
Round difficulty - Hard
This round was to test my coding aptitude. It was a 45 minutes round and I was asked 2 questions. One of the questions was based on Dynamic Programming and the other question was on Arrays that involved usage of Heaps. I was able to approach both the problems but could code only one due to time constraints. The interviewer was pretty friendly and quite helping. She guided me wherever I went wrong.
Given an infinite supply of coins of varying denominations, determine the total number of ways to make change for a specified value using these coins. If it's not possible to make...
The task is to find the total number of ways to make change for a specified value using given denominations.
Use dynamic programming to solve this problem efficiently.
Create a 2D array to store the number of ways to make change for each value up to the specified value.
Initialize the array with base cases and then iterate through the denominations to fill up the array.
The final answer will be in the last cell of the arra...
Tip 1 : Regular practice on online platforms
Tip 2 : Must do questions from geeksforgeeks.org are very helpful
Tip 3 : Experience in some team projects is a plus point
Tip 1 : Mention good projects in resume
Tip 2 : Team projects will help a lot
I appeared for an interview in Oct 2020.
Round duration - 60 minutes
Round difficulty - Medium
Given a positive integer N
, your task is to determine the minimum number of steps required to reduce N
to 1.
1) Subtract 1 from it: n = n -...
Implement a function to find the minimum steps to reduce a positive integer to 1 using given operations.
Use dynamic programming to store the minimum steps for each number from 1 to N.
Iterate through each number from 1 to N and calculate the minimum steps based on the given operations.
Consider the cases where N is divisible by 2 or 3, and also when subtracting 1 is the only option.
Return the minimum steps required to re
Round duration - 100 minutes
Round difficulty - Medium
My interview was held from 3 to 3:50 and 4 to 4:50 in the evening . I sat in a silent place of my room with no disturbances in my room.
The interviewer first asked me to introduce myself then he did the same, he then gave me a problem of sliding window and we discussed to reach on a optimal solution then I wrote the code for it . Then he asked me to ask if I had any questions , I asked some questions regarding their work culture , what do they expect from me and what work will I be given there as an SDE -intern. Second interview was almost the same the problem was of dynamic programming .
You are given an array/list of integers with length 'N'. A sliding window of size 'K' moves from the start to the end of the array. For each of the 'N'-'K'+1 possi...
The problem involves finding the maximum element in each sliding window of size 'K' in an array of integers.
Use a deque to store indices of elements in the current window in decreasing order of their values.
Remove indices that are out of the current window from the front of the deque.
Add the maximum element (at the front of the deque) to the result for each window.
Round duration - 50 minutes
Round difficulty - Medium
I have already given the description in the previous round.
Given an array "arr" consisting of "N" integer elements, your task is to remove "K" elements from the beginning or the end of the array. You must return the ma...
Given an array, remove K elements from beginning or end to maximize sum of remaining elements.
Iterate through all possible combinations of removing K elements from beginning and end
Calculate sum of remaining elements for each combination
Return the maximum sum obtained
Tip 1 : Solve as many questions and learn as many concepts as you can from gfg and leetcode.
Tip 2 : Solve the questions on notepad or notebook because there you won't get an editor to point out your mistakes.
Tip 3 : Submit your code when you are completely satisfied because there you won't get to run and debug your code.
Tip 1 : Keep it 1 page short and catchy.
Tip 2 : Do not brag in your Resume your resume should be honest and should represent exactly what you are.
based on 8 interviews
2 Interview rounds
based on 2 reviews
Rating in categories
Software Engineer
2k
salaries
| ₹18 L/yr - ₹62 L/yr |
Software Developer
1.3k
salaries
| ₹27.1 L/yr - ₹66.1 L/yr |
Senior Software Engineer
790
salaries
| ₹20.6 L/yr - ₹80 L/yr |
Data Scientist
282
salaries
| ₹33.4 L/yr - ₹60.8 L/yr |
Data Analyst
256
salaries
| ₹6.8 L/yr - ₹23 L/yr |
Yahoo
Amazon
Microsoft Corporation