add functionality of saving image when one is solved.