title: Function with return boolean value
body: <p>I am having hard time understanding the purpose of returning a boolean value in function.</p>
  
  <p>For example:</p>
  
  <pre><code>func withdraw(amount: Double) -&gt; Bool {
      if balance &gt; amount {
          balance -= amount
          return true
      } else {
          println("Insufficient funds")
          return false
      }
  }
  </code></pre>
  
  <p>What does it mean by <code>return true</code> or <code>return false</code>? What is the difference between <code>return true</code> and <code>return false</code>?</p>
  
  <p>Why do you want to return <code>true</code> or <code>false</code> instead of a function without any return?</p>
  
  <p>What is the value of <code>true</code> or <code>false</code> gonna be used for after it is returned from calling the function?</p>
  
  <p>Thank you.</p>