Google inc interview experience Real time questions & tips from candidates to crack your interview

Software Engineer Intern

Google inc
upvote
share-icon
3 rounds | 4 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 4 months
Topics: Data Structures, Alogrithms, Dynamic Programming, Trees and Graphs, OOPS (not asked by Google), Operating System (not asked by Google).
Tip
Tip

Tip 1 : Be thorough with all the standard data structures and algorithms.
Tip 2 : Give contests regularly on codeforces/codechef.
Tip 3 : Practise famous interview problems from past.

Application process
Where: Campus
Eligibility: Only students from circuital branches were allowed to apply.
Resume Tip
Resume tip

Tip 1 : Only mention the projects which you can properly explain to the interviewer.
Tip 2 : Elaborate the work done by you in bullet points.
Tip 3 : Try to keep the resume exactly 1 page long.

Interview rounds

01
Round
Medium
Online Coding Test
Duration60 Minutes
Interview date24 Jul 2021
Coding problem2

We had to solve 2 coding problems in 60 minutes. It was held in afternoon on hackerearth platform.

1. Largest Sub-Matrix With Equal 0’s And 1’s

Hard
0/120
Asked in companies
AmazonCodenationGoogle inc

You are given a matrix ā€˜ARR’ of size N * M. Each entry in this matrix is either 0 or 1.

Find the largest area of a rectangular sub-matrix that has an equal number of 0’s and 1’s in it.

Example :
If ā€˜N’ = 4 and ā€˜M’ = 5, and the matrix is:
0 1 0 1 1
0 1 0 1 0
0 1 0 1 1
0 1 0 1 1

Then clearly, the submatrix containing all the elements of the first four columns contains has equal number of 0’s and 1’s, the area of this submatrix is equal to 4 * 4 = 16, therefore we will print 16.
Follow Up :
Try to solve it in less than O( N^2 * M^2 ) time complexity.
Try solving now

2. Dijkstra's shortest path

Moderate
25m average time
65% success
0/80
Asked in companies
Deutsche BankPayPalPhonePe

You have been given an undirected graph of ā€˜V’ vertices (labeled 0,1,..., V-1) and ā€˜E’ edges. Each edge connecting two nodes (ā€˜X’,’Y’) will have a weight denoting the distance between node ā€˜X’ and node ā€˜Y’.

Your task is to find the shortest path distance from the source node, which is the node labeled as 0, to all vertices given in the graph.

Example:

Input:
4 5
0 1 5
0 2 8
1 2 9
1 3 2
2 3 6

alt text

In the given input, the number of vertices is 4, and the number of edges is 5.

In the input, following the number of vertices and edges, three numbers are given. The first number denotes node ā€˜X’, the second number denotes node ā€˜Y’ and the third number denotes the distance between node ā€˜X’ and ā€˜Y’.

As per the input, there is an edge between node 0 and node 1 and the distance between them is 5.

The vertices 0 and 2 have an edge between them and the distance between them is 8.
The vertices 1 and 2 have an edge between them and the distance between them is 9.
The vertices 1 and 3 have an edge between them and the distance between them is 2.
The vertices 2 and 3 have an edge between them and the distance between them is 6.

Note:

1. There are no self-loops(an edge connecting the vertex to itself) in the given graph.

2. There can be parallel edges i.e. two vertices can be directly connected by more than 1 edge.
Try solving now
02
Round
Hard
Video Call
Duration45 Minutes
Interview date3 Aug 2021
Coding problem1

This was the first coding interview round. It was held in morning. The interviewer gave his introduction and asked me to introduce myself. After this he quickly described the problem statement. I asked some questions related to the problem to ensure that i fully understand the statement and then proceded with my solution. The round lasted for close to 45 minutes and in that time i was able to satisfy the interviewer with my solution. The interviewer was very helpful.

1. Maths Question

We are given some inequalities like a > b or c < d, some of the inequalites are between two variables and some are between one variable and one constant number, find if all the inequalities can hold true simultaneously or not.

Problem approach

1. Corresponding to each inequality, i created a directed edge, for example if there is some inequality like a < b, then i create an edge starting from a and ending at b.
2. Then i created edges between all the integers in ascending order. For example if integers 1, 2 and 3 were appearing in some inequalities, then i created an edge between 1 and 2 and another between 2 and 3.
3. I searched for a cycle, if there exists one then it means that the inequalities can't hold true simultaneously else they can hold true.

03
Round
Hard
Video Call
Duration45 minutes
Interview date3 Aug 2021
Coding problem1

This was the second and final coding interview round. It was held in the afternoon almost 90 minutes after my first round. The interviewer introduced himself and i also gave my brief intro, then without wasting time he moved to the problem statement. I was able to solve the problem and code my solution when almost 10 minutes were still remaining. To utilise the remaining time, the interviewer added a few more conditions to the problem and asked me that how could i modify my solution wrt to the new conditions, we had a very casual discussion regarding this for almost 10 minutes.

1. Partition

Easy
10m average time
90% success
0/40
Asked in companies
FacebookAmazonMicrosoft

You are given a linked list and a number ā€˜x’, You have to partition the linked list in such a way that all nodes with a value less than 'x' comes before the nodes with values greater than or equal to 'x'. The original relative order should be preserved.

Try solving now

Here's your problem of the day

Solving this problem will increase your chance to get selected in this company

Skill covered: Programming

How do you remove whitespace from the start of a string?

Choose another skill to practice
Similar interview experiences
company logo
SDE - 1
1 rounds | 1 problems
Interviewed by Google inc
1573 views
0 comments
0 upvotes
company logo
SDE - Intern
3 rounds | 5 problems
Interviewed by Google inc
1279 views
0 comments
0 upvotes
company logo
L3 Engineer
3 rounds | 4 problems
Interviewed by Google inc
1706 views
0 comments
0 upvotes
company logo
SDE - Intern
3 rounds | 5 problems
Interviewed by Google inc
1370 views
0 comments
0 upvotes
Companies with similar interview experiences
company logo
Software Engineer Intern
4 rounds | 4 problems
Interviewed by Microsoft
1378 views
0 comments
0 upvotes
company logo
Software Engineer Intern
3 rounds | 9 problems
Interviewed by NCR Corporation
1260 views
0 comments
0 upvotes
company logo
Software Engineer Intern
2 rounds | 2 problems
Interviewed by CIS - Cyber Infrastructure
613 views
1 comments
0 upvotes