Discrete path planning, planning with cost n