title: How to check if a variable is set in Bash
body: <p>How do I know if a variable is set in Bash?</p>
  
  <p>For example, how do I check if the user gave the first parameter to a function?</p>
  
  <pre><code>function a {
      # if $1 is set ?
  }
  </code></pre>