Given two arrays, 'sizes' and 'directions' (0 for left, 1 for right), simulate fish swimming. If a right-moving fish meets a left-moving fish, the larger one eats the smaller one. Return the sizes of…
You've read your 3 free write-ups
Sign up free to keep reading. Your account opens the first 10 questions of every company.