Design an algorithm that takes a stream of integers and returns the product of the last k integers after each new number, with O(1) time per query expected. Only the approach was discussed. Here the…
You've read your 3 free write-ups
Sign up free to keep reading. Your account opens the first 10 questions of every company.