title: Combine int array to a single int
body: <p>I want to combine an integer array to a single integer value.  So I have the following code that will combine the array to a single value.  </p>
  
  <pre><code>int[] array = { 5, 6, 2, 4 };
  int combine = 0;
  
  for (int i = 0; i &lt; array.Length; i++)
  {
      combine += array[i] * Convert.ToInt32(Math.Pow(10, array.Length-i-1));
  }
  </code></pre>
  
  <p>this yield combine = 5624.  Which is correct. </p>
  
  <p>My issue is my array is not in the form of 0-9.  So my array could be {51,62,23,44}</p>
  
  <pre><code>int[] array = { 51, 62, 23, 44 };
  int combine = 0;
  
  for (int i = 0; i &lt; array.Length; i++)
  {
      combine += array[i] * Convert.ToInt32(Math.Pow(10, array.Length-i-1));
  }
  </code></pre>
  
  <p>yielding combine as 574774, not 51622344. How would I correct this?</p>