How do I read one number at a time and store duplicates into an array?
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/11819532/how-do-i-read-one-number-at-a-time-and-store-it-in-an-array-skipping-duplicates">How do I read one number at a time and store it in an array, skipping duplicates?</a>  </p>
</blockquote>



<p>I'm trying to read numbers from a file into an array, storing any duplicates. For instance, say the following numbers are in a file:</p>

<pre><code>41 254 14 145 244 220 254 34 135 14 34 25
</code></pre>

<p>Though the number 34 occurs twice in the file, I would only like to store it once in the array. How would I do this?</p>
