Google Onsite

Anonymous User
734
Feb 10, 2025
Feb 10, 2025

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 (5)