title: Get a specific digit of a number from an int in Java
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/2051817/return-first-digit-of-an-integer">Return first digit of an integer</a>  </p>
  </blockquote>
  
  
  
  <p>In my java program, I store a number in an array.</p>
  
  <pre><code>p1Wins[0] = 123;
  </code></pre>
  
  <p>How would I check the first digit of <code>p1Wins[0]</code>? Or the second or third? I just need to be able to find the value of any specific digit.</p>
  
  <p>Thanks!</p>