Update getCost()