title: Switch case for the index of an array
body: <pre><code>var testVar = [null, true, true, false, false];
  
  //Paulpro's solution (not mine)
  switch (testVar.indexOf( true )) {
    case 1:
      console.log('Im in the first group!');
      break;
    case 2:
      console.log('Im in the second group!');
      break;
    case 3:
      console.log('Im in the third group!');
      break;
  }
  </code></pre>
  
  <p>testVar is an array like this [null, true, true, false, false, false] for an employee in the first group (index 1 is true) AND second group, but not the third group.</p>