It sort of makes sense. But not really (ala: 'simple explantation').
Sounds like CGI/HTML input forms !?
To try and answer the
No need to append the elements of array(Y) into the last element of array(X).
Though it can work if you do some text manipulation, it would be silly.
I don't really understand the proposition that you have made. But, it would be better to do position tracking via external array's or just a hash, or just multi-dimensional arrays.
I think I just dont understand your scenario enough. Maybe just use mutli-dimensional arrays, ie;
$array[$n][$m].
There are plenty of ways of doing things :- ).