Assume that having 3 array object: $main, $one, $two
How to Insert multiple array object into another array randomly not mixing elements of any single array object elements
$main = (1,2,3,4,5); $one = ("orange", "apple"); $two = ("car", "bus", "train");
I need to insert array object elements '$one' and '$two' in random position of array '$main' with whole set of both array object elements without mixing.
Resulting array:
$result = (1, 2, "orange", "apple", 3, 4, "car", "bus", "train", 5);
Please comments if you are not getting my question. This would be a great help if answered.
Thanks a lot in advance.