I have an array of 350 values (collected from an API).
Now in order to filter i allow the user to select an unknown amount of countries.
An example of this could be the following
$countries = array
(
0 => 'Denmark',
1 => 'Sweden',
2 => 'United states',
3 => 'Norway'
);
Now i want to check that atleast one of the values is in my data array
i know that i am able to do this by looping through all of them and checking each individually. but if i could i really want to avoid that.
So is there a way to do such a thing in PHP?