trying to solve p5..