Solution to challenge problem by our planner