added solution to challenge problem