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

Software Engineer

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

Interview preparation journey

expand-icon
Preparation
Duration: 6 months
Topics: Data Structures, Algorithms, OOP, Operating Systems, Computer Networks, Database Management Systems
Tip
Tip

Tip 1 : Data Structure and Algorithms is the most important topic. Make sure you have clear basics, practise a lot of problems, and keep revising the concepts.
Tip 2 : To make your resume attractive, participate in hackathons, do competitive programming, contribute to open source, do some internships.
Tip 3 : Have a strong hold on core CS subjects like Operating System, OOP, Computer Networks, Databases. (Though Google only focuses on DSA, its good to know because they can come up anytime during an interview.)

Application process
Where: Campus
Eligibility: NA
Resume Tip
Resume tip

Tip 1 : Follow Google Resume video tips from Youtube
Tip 2 : When a recruiter looks at your resume, she wants to know two things. First is can this guy crack the DSA rounds. And second is has this guy done some hands on work (development). Make sure your resume answers this.

Interview rounds

01
Round
Medium
Video Call
Duration45 minutes
Interview date10 Feb 2022
Coding problem3

This was a Phone screening round. I they like me they would go ahead with my onsites.

1. Replace Spaces

Easy
15m average time
85% success
0/40
Asked in companies
MicrosoftAmazonPayPal

You have been given a string 'STR' of words. You need to replace all the spaces between words with “@40”.

Try solving now

2. Minimum Card Flips

Moderate
0/80
Asked in company
Google inc

You are at your friend’s birthday party and one of your friends decided to play a card game with some special type of cards. These cards can have numbers written on both sides.

You are given ‘N’ cards, each card contains some integer number between ‘1’ to ‘10’ written on both sides. You are allowed to flip a card such that the number which was previously on the top now comes at the bottom and vice versa.

Find the minimum flips that need to be performed to make all the numbers equal on either the top sides or the bottom sides. If it is impossible to make all the cards the same on either side then return ‘-1’.

For Example :
If N = 4 and the numbers on the top sides are: { 1, 2, 3, 2 } and the numbers on the bottom sides are: { 2, 4, 2, 2}

Then the minimum number of flips required is equal to 1.
We can flip the 2nd card, the top sides now become: { 1, 4, 3, 2 } and the bottom sides are: { 2, 2, 2, 2}. This results in getting the same numbers on the bottom side.
Try solving now

3. A Number Game

Moderate
0/80
Asked in company
Google inc

Ninja has an integer 'A'.

He will go through all integers 'X' from 1 to 10^18 and for every 'X', he will store the value of 'LCM(X,A) ÷ X'.

He wants to know the number of unique values he will obtain in the end.

Example :
‘A’ = '2'
For X = 1, Ninja will get LCM(1,2) ÷ 1 = 2/1 = 2.
For X = 2, Ninja will get LCM (2,2) ÷ 2 = 2/2 = 1.
For X = 3, Ninja will get LCM (3,2) ÷ 3  = 6/3 = 2.
For X = 4, Ninja will get LCM (4,2) ÷ 4 = 4/2 = 2.
For X = 5, Ninja will get LCM (5,2) ÷ 5 = 10/2 = 2.
For X = 6, Ninja will get LCM (6,2) ÷ 6 = 6/6 = 1.
And so on, It can be verified that Ninja will never get any integer other than 1 and 2. Hence the answer for 'A' = 2 is 2.
Try solving now
02
Round
Easy
Video Call
Duration45 minutes
Interview date16 Feb 2022
Coding problem2

It was my first onsite rounds. They scheduled two onsite rounds on the same day.

1. Longest Path

Moderate
25m average time
65% success
0/80
Asked in company
Google inc

You have been practicing on the topic binary tree for a few days. Your friend challenges you by giving you a binary tree with ‘N’ nodes in which each node has a weight associated with it and asks you to find the largest number of edges such that the nodes connecting those edges have the same weight.

Note :

1. Two nodes may have the same value associated with it.
2. The root node will be fixed and will be provided in the function.
Try solving now

2. Longest Consequence

Moderate
25m average time
70% success
0/80
Asked in companies
BytedanceGoogle inc

You are given a binary tree consisting of ‘N’ nodes. Each node has an integer value assigned to it. Ninja recently learned about tree algorithms and the teacher gave him an assignment on it.

You need to find the length of the longest path in this tree which comprises nodes with consecutive values in increasing order. Every node is considered a path of length 1.

The path refers to any sequence of nodes from some starting node to any node in the tree along the parent-child connections. The longest consecutive path needs to be from parent to child (cannot be the reverse).

Problem approach

I wasnt able to solve this problem

Try solving now
03
Round
Easy
Video Call
Duration60 minutes
Interview date10 Feb 2022
Coding problem1

Second round was DSA+Googlyness

1. Cut Into Segments

Moderate
25m average time
75% success
0/80
Asked in companies
DunzoGoogle incFlipkart limited

You are given an integer ‘N’ denoting the length of the rod. You need to determine the maximum number of segments you can make of this rod provided that each segment should be of the length 'X', 'Y', or 'Z'.

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
Software Engineer
4 rounds | 4 problems
Interviewed by Google inc
0 views
0 comments
0 upvotes
company logo
Software Engineer
4 rounds | 4 problems
Interviewed by Google inc
5111 views
2 comments
0 upvotes
company logo
Software Engineer
2 rounds | 4 problems
Interviewed by Google inc
2292 views
0 comments
0 upvotes
company logo
Software Engineer
3 rounds | 4 problems
Interviewed by Google inc
1492 views
1 comments
0 upvotes
Companies with similar interview experiences
company logo
Software Engineer
3 rounds | 7 problems
Interviewed by Optum
7976 views
1 comments
0 upvotes
company logo
Software Engineer
5 rounds | 5 problems
Interviewed by Microsoft
10147 views
1 comments
0 upvotes
company logo
Software Engineer
2 rounds | 4 problems
Interviewed by Amazon
4447 views
1 comments
0 upvotes