improve nearest() && itinerary(), working solve()