PHP Arrays What will be the output of the following PHP code?$names = array("Sam", "Bob", "Jack");echo $names[0] . "is the brother of " . $names[1] . " and " . $names[1] . "."; Sam is the brother of Jack and Bob) Sam is the brother of Bob and Jack Error Sam is the brother of Bob and Bob) Sam is the brother of Jack and Bob) Sam is the brother of Bob and Jack Error Sam is the brother of Bob and Bob) ANSWER DOWNLOAD EXAMIANS APP
PHP Arrays What functions count elements in an array?1. count2. Sizeof3. Array_Count4. Count_array Option 1 and 4 Option 3 and 4 Option 1 and 2 Option 2 and 4 Option 1 and 4 Option 3 and 4 Option 1 and 2 Option 2 and 4 ANSWER DOWNLOAD EXAMIANS APP
PHP Arrays What will be the output of the following PHP code?$fruits = array ("apple", "mango", "peach", "pear", "orange");$subset = array_splice ($fruits, 2);print_r ($fruits); Array ( [0] => apple [1] => mango ) Array ( [0] => pear [1] => orange ) Error Array ( [0] => apple [1] => mango [2] => peach ) Array ( [0] => apple [1] => mango ) Array ( [0] => pear [1] => orange ) Error Array ( [0] => apple [1] => mango [2] => peach ) ANSWER DOWNLOAD EXAMIANS APP
PHP Arrays What will be the output of the following PHP code?$cars = array("Volvo", "BMW", "Toyota");echo "I like " . $cars[2] . ", " . $cars[1] . " and " . $cars[0] . "."; I like Toyota, BMW and Volvo I like Volvo, BMW and Toyota I like Volvo, Toyota and BMW I like BMW, Volvo and Toyota I like Toyota, BMW and Volvo I like Volvo, BMW and Toyota I like Volvo, Toyota and BMW I like BMW, Volvo and Toyota ANSWER DOWNLOAD EXAMIANS APP
PHP Arrays What will be the output of the following PHP code?$a = array("red", "green", "blue");array_pop($a);print_r($a); Array ( [0] => green [1] => blue ) Array ( [0] => red [1] => blue ) Array ( [0] => red [1] => green ) Array ( [0] => blue [1] => blue ) Array ( [0] => green [1] => blue ) Array ( [0] => red [1] => blue ) Array ( [0] => red [1] => green ) Array ( [0] => blue [1] => blue ) ANSWER DOWNLOAD EXAMIANS APP
PHP Arrays What will be the output of the following PHP code?$state = array ("Karnataka", "Goa", "Tamil Nadu", "Andhra Pradesh");echo (array_search ("Tamil Nadu", $state) ); False True 2 1 False True 2 1 ANSWER DOWNLOAD EXAMIANS APP