title: Python printing a procedure
body: <p>I am trying to print a procedure in Python. How do I print it?
    Here is my code</p>
  
  <pre><code>def proc(a,b):
      if test(a):
          return b
      return a
  
  print proc(a,b)
  </code></pre>
  
  <p>But I get this error:</p>
  
  <blockquote>
    <p>NameError: name 'a' is not defined</p>
  </blockquote>
  
  <p>Thanks in advance.    </p>