title: How to get numbers that haven't been selected
body: <p>How do I make a function returns a different number than the previous return, until it has returned all provided numbers.</p>
  
  <p>I have this function (which returns a random number between max and min), and I call it every second:</p>
  
  <pre><code>private function randomNumber(maxNumber:int, minNumber:int = 0):int
      {
          return Math.floor(Math.random() * (1 + maxNumber - minNumber) + minNumber);
      }
  </code></pre>
  
  <p>Let's say the 1st time it returns the number <strong>2</strong>. The 2nd time it has to return <strong>1</strong>, <strong>3</strong> or <strong>4</strong>, and lets say it gives back <strong>4</strong>. The 3rd time it has to return <strong>1</strong> or <strong>3</strong>, and lets say it gives back <strong>1</strong>. And in the end, it has nothing left to return except 1, and it returns it.</p>
  
  <p>How do I make it so I only get a number once until I have been given all of them.
  And when that occurs, I can reset the function so I can get again a random number from <strong>1</strong> to <strong>4</strong>. And repeat this indefinitely.</p>