The Optimal Method for Solving Continuous Linear and Nonlinear Programs