title: How to improve the uniformly distributed of a given random function to generate uniformly distributed numbers?
body: <p>The question is related on Linux like Debian or Ubuntu, bash and a given function which use RANDOM.</p>
  <p>Every improvement should use bash only.</p>
  <p>Given are the follow function:</p>
  <pre><code>getRND(){
      min=&quot;${1:-1}&quot;   ## min is the first parameter, or 1 if no parameter is given           
      max=&quot;${2:-100}&quot; ## max is the second parameter, or 100 if no parameter is given
      rnd_count=$((RANDOM%(max-min+1)+min));
      echo &quot;$rnd_count&quot;
  }
  
  var=$(getRND -10 10) # Call the function
  echo $var # output
  </code></pre>
  <p>How too:</p>
  <ul>
  <li>Improve the randomness</li>
  </ul>
  <p>The solution is sought for Linux systems on which no bash 5.1 is installed already and therefore no SRANDOM can be used up to now.</p>