Calculating the mean and variance with one pass · HackerTrans