title: Iterating over a subset of a set
body: <p>I have a set oneHundredInactiveSynapses and I would like to manipulate a random 21 of the 100 inactiveSynapses in that set and then stop. I feel like there should be a easy way to do this, but I just can't think of anything right now.</p>
  
  <pre><code>for (Synapse inactiveSynapse : oneHundredInactiveSynapses) {
      // I want to call a method on the inactiveSynapse like
          inactiveSynapse.setActiveState(true);
          // but I only want to do this to 21 of the synapses. How can I do this?
  }
  </code></pre>
  
  <p>Other points:</p>
  
  <ol>
  <li>making oneHundredInactiveSynapses into an array is not an option</li>
  <li>I don't care which 21 become active</li>
  </ol>