I am having trouble trying to figure out how to increase size a of an array A so that A has a large enough buffer at the end to hold an array B.
Assuming the two sorted arrays are A = {1, 3, 5}
and B = {2, 4, 6, 8}
A = {1, 3, 5, 0, 0, 0, 0}
and B = {2, 4, 6, 8}
where A has buffer {0, 0, 0, 0}
at the end to hold B