Update solution

solution to the input i just posted