implemented op_minpath