title: Sampling from an array
body: <p>I have a float array containing 1M floats</p>
  
  <p>I want to do sampling: for each 4 floats I want to take only 1. So i am doing this :</p>
  
  <pre><code>for(int i = 0; i&lt; floatArray.Length; i++) {
      if(i % 4 == 0) {
           resultFloat.Add(floatArray[i])
      }
  }
  </code></pre>
  
  <p>This works fine, but it takes much time to run through all the elements , is there any other methods to make it with better results (if there are any)</p>