title: Testing empty variables
body: <p>I have a large number of variables in my script, and I want the script to error out if any one of the variables are empty.</p>
  
  <p>I know I can:</p>
  
  <pre><code>if [[ -z "$var_1" ]] || [[ -z "$var_2" ]] || ... [[ -z "$var_n" ]]; then
    # failure message
  fi
  </code></pre>
  
  <p>However, I cannot inform the user which variable was empty if I do it in this way. Is there an alternative approach to the above so that I can inform the user about the empty variable?</p>