I have a random process that, when called, returns a random number between 0 and K-1, where K may be decently high. I want to keep track of the number of times any outcome occurs, and normalize all the counts into a probability distribution. I want to do this every time I call the random process so that my distribution estimate of the random process is as up-to-date as possible.I have a random process that, when called, retu