Adding get MaxPath solution