I\'ve got an array of arrays that may have a different count of elements when the script is run.
$strict = [
[0] => [\'one\', \'two\', \'three\', \'f
You can use call_user_func_array:
Call a callback with an array of parameters
So your callback would be array_intersect
, and you could pass your array like this:
$result = call_user_func_array('array_intersect', $strict);
You can take advantage of modern PHP's array packing/unpacking features - aka variadics, or the so-called "splat" (...
) operator - as well:
$result = array_intersect(...$strict);