I have a PHP array.
Let's say
$array = array(20,1,0, 0, 0,0,8);
I need to check whether at least tow values available greater than 0 in the array. As an example.
$array = array(20,1,0, 0, 0,0,8);
// True - Above array has at least two values which is > 0
$array = array(0,9,0, 0, 0,0,0);
// False- Above array doesn't have at least two values which is > 0
I would like to know if there any easy way to get this done without looping through the array.
Thank you.