title: generate random number using specific digits in javascript
body: <p>In my program I want to generate 5 digit random number such the that contain only digits ( 1 to 7).</p>
  
  <pre><code>var randnum = Math.floor(Math.random() * (11111 - 77777 + 1)) + 11111;
  </code></pre>
  
  <p>Using above code I got number between <code>11111</code> and <code>77777</code>. But how to generate the number that does not contain <code>0,8,9</code>  ? Is there any default method to generate this kind of numbers?</p>