update solutions for problems 1, 2