Compress If Conditions
<p>Is there such a way to compress a block of conditions in an <code>if</code> statement?
As you can see from the code, <code>itemKey</code> is a variable. I set the first letter to be lowercased so I can match it to another variable <code>letter</code>.  The below works perfectly, but I would like to clean it up. Can I somehow pull all the <code>||</code> after the <code>&amp;&amp;</code> together to encompass all number 0-9? This is acting as a <code>string</code>, not <code>integer</code>.</p>

<pre><code>firstLetterLower = itemKey.charAt(0).toLowerCase();
if(firstLetterLower==letter || (letter=='number' &amp;&amp; (firstLetterLower=='0' || firstLetterLower=='1' || firstLetterLower=='2' || firstLetterLower=='3' || firstLetterLower=='4' || firstLetterLower=='5' || firstLetterLower=='6' || firstLetterLower=='7' || firstLetterLower=='8' || firstLetterLower=='9'))) {
</code></pre>
