question: private < T > T [ ] concat ( T [ ] first , T [ ] second , Class < ? > cls ) { Collection < T > res = new ArrayList < > ( ) ; res . addAll ( Arrays . asList ( first ) ) ; res . addAll ( Arrays . asList ( second ) ) ; return res . toArray ( ( T [ ] ) Array . newInstance ( cls , res . size ( ) ) ) ; }
target:  Returns a new array that contains the concatenated contents of two arrays.