I would like to know if there is any native function of PHP to relate all the items of arrays with all the items of other arrays, for example:
$arr['a'] = [1,2,3];
$arr['b'] = [4,5];
$arr['c'] = [7,8,9,10];
To get the following result:
$result[] = [1,4,7];
$result[] = [1,4,8];
$result[] = [1,4,9];
$result[] = [1,4,10];
$result[] = [1,5,7];
$result[] = [1,5,8];
And so on, until all have been related, and the initial arrays can vary in number as well as their contents.