min_cost updated