Solving for x and finding the solution