permutation of integer arrays
<p>I want a Java code for permutation of <code>int</code> arrays.</p>

<p>Suppose an input of <code>1 2 3</code> and the program would return all the possible combinations of these elements.</p>

<p>I have written a Java code which takes <code>String</code> array as an input and returns <code>int</code> array. But when I convert a <code>String</code> into an <code>int</code> array, I am facing a problem. The problem is that suppose I give an input of <code>10 20 2</code>, it goes <code>int</code> the <code>String</code> as <code>10 20 2</code> as it is. But on converting it into an <code>int</code> array it is getting converted as <code>1 0 2 0 2</code>.</p>

<p>So plz post some Java code which does not need <code>String</code> conversion into an <code>int</code> array or plz give me suggestion so that i would get <code>10 20 2</code> in the <code>int</code> array in spite of <code>1 0 2 0</code>. I have used the following code for <code>String</code> to <code>int</code> array conversion.</p>

<pre><code>for (int j= 0; j &lt; array[in].length(); j++) {
    intArray[j] = Character.digit(array[in].charAt(j), 10);
}
</code></pre>

<p>Plz reply as soon as possible.</p>
