title: How to return the right positive number in python whithou changing the initial variable?
body: <p>I have create functions to simulate ATM system, when asking the user to make deposit everything goes well but the problem is when the user make a withdraw. If the amount is greater than the balance I have the new balance in negative value. And need some help to correct this behavior.</p>
  <p><strong>My functions:</strong></p>
  <pre><code>def show_balance(balance):
      print(f&quot;Current Balance: ${balance}&quot;)
  
  def deposit(balance):
      amount = input(&quot;Enter amount to deposit: &quot;)
      amount = float(amount)
      result = balance + amount
      return result
  
  def withdraw(balance):
      withdraw = input(&quot;Enter amount to withdraw: &quot;)
      withdraw = float(withdraw)
      result = balance - withdraw    
      return result
  </code></pre>
  <p><strong>Here is when using the functions:</strong></p>
  <pre><code># Display ATM menu to user
  while True:
      option = input(&quot;Choose an option: &quot;)
      if option == &quot;1&quot;:
          account.show_balance(balance)
      elif option == &quot;2&quot;:
          balance = account.deposit(balance)
          account.show_balance(balance)
      elif option == &quot;3&quot;:        
          balance = account.withdraw(balance)
          account.show_balance(balance)
          while True:
              if balance &lt; 0:
                  print(&quot;You do not have this money?&quot;)
                  break
      else:
          print(&quot;Please, provide a valid option&quot;)
  </code></pre>
  <p>Now when adding 50 using option &quot;2&quot; everithing works well. When the withdraw is &lt; the balance (55) it just return a nagative value (-5). I want to print the massage: &quot;You do not have this money?&quot;, but also keep the balance to the right amount (50 -55) =&gt; balance remain 50 and ask the user to try again.</p>