public static final int[] toIntArray(String s){
  int[] array=new int[s.length()];
  for (int i=0; i < s.length(); i++) {
    array[i]=Character.digit(s.charAt(i),10);
  }
  return array;
}

public static final int [ ] toIntArray ( String s ) { int [ ] array = new int [ s . length ( ) ] ; for ( int i = 0 ; i < s . length ( ) ; i ++ ) { array [ i ] = Character . digit ( s . charAt ( i ) , 10 ) ; } return array ; }
convert eg " 12 " to [ 1 , 2 ] . see also mlutils . tointarray ( string s ) < br >
