diff --git a/ortools/linear_solver/samples/linear_programming_example.py b/ortools/linear_solver/samples/linear_programming_example.py index ca48569c13..d71f744621 100644 --- a/ortools/linear_solver/samples/linear_programming_example.py +++ b/ortools/linear_solver/samples/linear_programming_example.py @@ -27,10 +27,10 @@ def LinearProgrammingExample(): pywraplp.Solver.GLOP_LINEAR_PROGRAMMING) # [END solver] - # Create the two variables and let them take on any value. + # Create the two variables and let them take on any non-negative value. # [START variables] - x = solver.NumVar(-solver.infinity(), solver.infinity(), 'x') - y = solver.NumVar(-solver.infinity(), solver.infinity(), 'y') + x = solver.NumVar(0, solver.infinity(), 'x') + y = solver.NumVar(0, solver.infinity(), 'y') # [END variables] # [START constraints]