Added code to handle when all prices are 0.