#3 -> Fix updateAverageCostMC