Better way of agregating result