Here you can find the source of combineIntArrays(int[] A, int[] B)
public static int[] combineIntArrays(int[] A, int[] B)
//package com.java2s; //License from project: Open Source License public class Main { public static int[] combineIntArrays(int[] A, int[] B) { int[] toReturn = new int[A.length + B.length]; for (int i = 0; i < toReturn.length; i++) { if (i < A.length) { toReturn[i] = A[i];/*from w ww . j a v a 2 s . c om*/ } else { toReturn[i] = B[i - A.length]; } } return toReturn; } }