Computer Science, asked by sahasreddy, 9 months ago

can we merge two same arrays in java​

Answers

Answered by aasrithaambati14
0

Explanation:

There are following ways to merge two arrays: Java arraycopy() method.

...

For example:

1] int[] arr1={1, 2, 3, 4, 5, 6}; //first array.

2] int[] arr2={7, 8, 9, 0}; //second array.

3] int[] arr3={1, 2, 3, 4, 5, 6, 7, 8, 9, 0} //resultant array.

Answered by NikitaBK
0

Answer:

Merging two arrays in Java is similar to concatenate or combine two arrays in a single array object. We have to merge two arrays such that the array elements maintain their original order in the newly merged array. The elements of the first array precede the elements of the second array in the newly merged array.

Explanation:

is it helpful

Similar questions