Sail E0 Webinar
Question
What will be the output of the following PHP code?$foods = array("pasta", "steak", "fish", "potatoes");$food = preg_grep("/^s/", $foods);print_r($food);
Options:
A .  Array ( [1] => steak )
B .  Array ( [0] => pasta [1] => steak [2] => fish [3] => potatoes )
C .  Array ( [0] => potatoes )
D .  Array ( [3] => potatoes )
Answer: Option A

Submit Your Solution Below and Earn Points !
Next Question

Submit Solution

Your email address will not be published. Required fields are marked *

More Questions on This Topic :


Latest Videos

Latest Test Papers