I don't understand the use case of count min sketch. Based on Count–min sketch, it says "serves as a frequency table of events in a stream of data.".
If I know there are N types of events, why can't I just allocate an array of N slots or a hashmap to keep track of the event frequencies as the stream is ingested?
Am I right to say the use case is when N is unknown or N is so large that it is not possible to keep the entire frequency array/hashmap in memory?