Solution to problem id pper