UnboundLocalError: local variable 'user_a' referenced before assignment
<p>I really cannot figure out how to make the code below work. I am getting this exception:</p>

<blockquote>
  <p>UnboundLocalError: local variable 'u' referenced before assignment</p>
</blockquote>

<pre><code>user_a = "No selection"
def if_statement():
    user_choice = input("Pick 1 or 2\n")
    if user_choice == "1":
        user_a = input("What would you like A to equal?\n")
        if_statement()
    elif user_choice == "2":
        print("A equals: " + user_a)
        if_statement()
if_statement()
</code></pre>

<p>Can anybody help me on this? I must specify that I am new to Python.
Thank you in advance.</p>