Google Onsite

Difficulty: EASYCategory: InterviewExperienceFrequency: 1Asked On 2025-02-10Added By Anonymous
Source: Link
🧭 Experience: unknown
✅ Outcome: unknown
💰 Compensation: unknown
📍 Location: unknown
🏢 Company: Google
🎓 Education: unknown
🎁 Benefits: unknown
📅 Offer Date: unknown

R1. Given a list jobids that are successfully ack arrays [1, 2, 3, 5, 7, 4 8] at any given time return the max ack jobId in sequence eg 0 -> 1, 1->2 3->3 4 -> 3, 5-> 3, 6-> 5

R2. Given a 3 digit lock with digits ranging from 1-n and there are 2 combinations that can open a lock 1 user 2 factory and you have a offeset k any combination with offset can open the lock return the total no combinations that can open the lock

R3. there is a merge function that takes 2 sorted string and merges them like merge sort you are given a string and a dictionary with contains(string) method that will tell if word is present. you have to implement unmerge() function eg :

x = "acfgh" y = "bdlmn"

s = "abcdfghlmn"

unmerge( s ) returns {"acfgh", "bdlmn"}
Comments