Updates according to the solution.