title: Finding Closest Matching Value using jQuery or javascript
body: <p>Consider a markup such as </p>
  
  <pre><code>&lt;select id="blah"&gt;
    &lt;option value="3"&gt;Some text&lt;/option&gt;
    &lt;option value="4"&gt;Some text&lt;/option&gt;
    &lt;option value="8"&gt;Some text&lt;/option&gt; // &lt;---- target this tag based on value 7
    &lt;option value="19"&gt;Some text&lt;/option&gt;
  &lt;/select&gt;
  </code></pre>
  
  <p>Suppose I have a value with me, say 7. Is it possible to target the option tag whose <code>value</code> attribute is closest to 7 which, in this case, would be <code>&lt;option value="8"&gt;</code>?</p>
  
  <p>I'm aware of <code>^</code> which means starting with and <code>$</code> which means ending with and was hoping if there is something like this to find the closest match for a given value.</p>