google logo
Google· SDE II

Google L4 Interview Experience

Posted
14 Jul 2025
431 reads

Summary

I interviewed for an L4 position at Google, completing a pre-screening and three onsite rounds. The interviews covered API implementations for restaurant table allocation and a chat system, an IP address to city mapping problem, and a modified greedy/knapsack type question. I was rejected after the third onsite round.

How it went

Recruiter from Google's Talent Acquisition Partner companies reached out via call.

Pre - screeing Round

  • Interviewer was from Switzerland (about 35y)
  • Asked a question to implement few APIs for Restaurant table allocation.
  • JoinWaitlist() (A group of people will join the restaurant waitlist)
  • LeaveWaitlist()
  • AllocateTable(int size) => Allocate the table to the first group which has a groupsize = size, if no such group allocate to size-1,-2 etc.
  • It was not that difficult I would rate the difficulty somewhere between implementing a LRU Cache and LFU Cache.
  • Feedback - Very good

Onsite Round 1

  • Interviewer from Bangalore/Hyderabad (about 28y)
  • Implement few Chat related APIs (I dont exactly remember)
  • You have kind of a fream of messages of format
  • (From, To, Message),(From, To, message)...
  • Needed to implement APIs like
  • UserWithMostChats()
  • DeleteUser() => (all chats should be removed from other users as well)
  • Some other APIs I dont remember
  • This was also not that difficult
  • Feedback : Good

Onsite Round 2

  • Interviewer from Bangalore/Hyderabad (about 40-45y)
  • Given Ip address ranges and their corresponding city
  • (IP_Start, IP_End, "Arizona"),... etc
  • You will be given an IP address find which city it belongs to
  • Binary search question, asked in google interviews several times
  • I though it will be very simple
  • Got kind of confused while writing high/low update conditions, missed 2 edge cases also :(
  • Feedback : Bad (Comment : Missed edge cases, quoted wrong Time Complexity (Dont when when this happened!))

Onsite Round 3

  • Interviewer from Bangalore/Hyderabad (about 28y)
  • Started with simple greedy question (almost same as fractional knapsack)
  • Modified it to be a Heap based greedy question
  • I arrived at the optimal solution during discussion but there was no time to code it.
  • Feedback : Bad (Comment: Didnt leave enough time to complete question)

Rejected after this, Round 4 didnt happen (Behavioral)!

Questions asked (3)

  1. 01

    Restaurant Table Allocation System

    Data Structures & Algorithms · Medium

    Implement APIs for a restaurant table allocation system:

    • JoinWaitlist(): A group of people will join the restaurant waitlist.
    • LeaveWaitlist()
    • AllocateTable(int size): Allocate a table to the first group which has a group size = size. If no such group exists, allocate to a group with size-1, size-2, etc.
  2. 02

    Chat System APIs

    Data Structures & Algorithms · Medium

    Given a stream of messages in the format (From, To, Message), implement the following APIs:

    • UserWithMostChats(): Return the user who has sent or received the most chats.
    • DeleteUser(): All chats involving this user should be removed from other users as well.
  3. 03

    IP Address to City Mapping

    Data Structures & Algorithms · Medium

    Given a list of IP address ranges and their corresponding cities (e.g., (IP_Start, IP_End, "Arizona"),... etc), implement a function that, given an IP address, finds which city it belongs to.

Know someone preparing? Send it to them:WhatsAppLinkedInX

Interviewed at Google recently?

Write up your rounds while you still remember the questions. It helps the next person more than you would think.

Share your experience
Discussion 0

Questions for the author, or how your own interview compared.

Join the discussion

Sign in with Google to comment or ask the author a question.

No comments yet

Be the first to share your thoughts and start the discussion!