title: Python Change Variables without Changing Parameters
body: <p>Is there a way to change the variables z, a, b, c, and d without modifying the parameters of func1? The reason is that I'm trying to iterate from values 0 to 100 for z, a, b, c, and d to find an optimal / best solution to a problem I'm working on. However, normally, z, a, b, c, and d are constants.</p>
  
  <pre><code>def func1(x, y):
      if x &gt; z:
          return 0
      if (x + y) &gt; 0:
          return func2(x, y, a, c)
      return func2(x, y, b, d)
  </code></pre>