Skip to content
Related Articles

Related Articles

Google Interview Experience | On-Site for SDE
  • Difficulty Level : Hard
  • Last Updated : 02 Mar, 2020
GeeksforGeeks - Summer Carnival Banner

So the on-site interview comprised of five rounds in total. 4 technical rounds and 1 googliness round.

Round 1:  There are several equations given in terms of two variables with a ‘<‘ or ‘>’ sign between them. Ex – a > b, b > c etc. You have to answer whether there is a sequence which of the variables which will satisfy all the equations given.

My approach : I solved it as a graph problem. All the variables were converted into the nodes of a graph. An edge between them signified the relation between them. If the directed graph did not contain a cycle, then it was possible to have an answer.

Round 2:  It was something like this with a little variation that the total number of moves were limited to a number t.

My approach : I gave a recursive approach and then a dynamic programming solution. The interviewer helped me to get to the final solution which was possible in O(n) time complexity and O(1) space complexity.

Round 3: Suppose you have an array consisting of 0 and 1. Find the total number of subarrays of o.

Ex – array : 00101

Ans : { “0”, “0”, “00”, “0”} – 4

My Approach : First I found the number of subarrays (of 0) in the main array. Ex – 2 in the above example. Then I applied the formula (n+1)(n)/2 on each size of subarray.

Round 4 :  This was a classical dynamic programming problem of palindrome partitioning.

My Approach :

Round 5 : This was a pretty easy round compared to others. General questions were asked like what are the skills that you want in your manager, how should a company play a role in social and environmental development, what are the basic qualities that you look in an employee, how do you work in a team etc.

All in all it was a good experience. Remember to be quick and very precise about your answers. The questions may seem easy but they are actually grading you on your accuracy, efficacy and quickness to respond.

Attention reader! Don’t stop learning now. Get hold of all the important DSA concepts with the DSA Self Paced Course at a student-friendly price and become industry ready.  To complete your preparation from learning a language to DS Algo and many more,  please refer Complete Interview Preparation Course.   In case you are prepared, test your skills using TCS, Wipro, Amazon and Microsoft Test Serieses.

My Personal Notes arrow_drop_up
Recommended Articles
Page :