Computer Science, asked by Anonymous, 11 months ago

don't post useless answer please. mind ka fuse vese he uda hua hai ⚠

.Write a statement to join two array named arr1 and arr2 horizontally(row)​

Answers

Answered by shuklalavi059
1

Answer:

Create an array arr3[] of size n1 + n2.

Copy all n1 elements of arr1[] to arr3[]

Traverse arr2[] and one by one insert elements (like insertion sort) of arr3[] to arr1[]. This step take O(n1 * n2) time.

We have discussed implementation of above method in Merge two sorted arrays with O(1) extra space

Answered by Anonymous
1

in python

ar1=[1,2,3]

ar2=[4,5]

ar=ar1+ar2

Similar questions