Object-Oriented Programming · Akuna Capital · Medium
You need to process a stream of numbers, first by designing a basic data recorder, then by making the recorder operate over a sliding window of the most recent elements. Stage 1 – Duplicate Removal Write a function that accepts a sequence of values and returns a new sequence containing only the first occurrence of each value, preserving the original order. Use a hash table (e.g., a set) to track the elements you have already seen. Stage 2 – Global Statistics Tracker…
Checking your access…