Java Integer Array to String intArray2String(int[] xs)

Here you can find the source of intArray2String(int[] xs)

Description

int Array String

License

Apache License

Declaration

public static String intArray2String(int[] xs) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {
    public static String intArray2String(int[] xs) {
        StringBuilder sb = new StringBuilder();

        for (int i = 0; i < xs.length; ++i) {
            sb.append(Integer.toString(xs[i]));
            if (i < xs.length - 1) {
                sb.append(",");
            }//from   w  w w .j  av  a 2 s  . c  o m
        }

        return sb.toString();
    }
}

Related

  1. convertIntArrayToString(int[] value, String separator)
  2. inputStreamToStr(InputStream is)
  3. inputStreamToStr(InputStream is)
  4. intArray2string(int intarr[])
  5. intArray2String(int[] value)
  6. intArrayAsString(int[] a)
  7. intArrayToString(final int... ints)
  8. intArrayToString(int vals[])
  9. intArraytoString(int[] a)