PHP Arrays What elements will the following script output?$array = array (true => 'a', 1 => 'b');var_dump ($array); True => 'a', 1 => 'b' It will output NULL None 1 => 'b' True => 'a', 1 => 'b' It will output NULL None 1 => 'b' ANSWER DOWNLOAD EXAMIANS APP
PHP Arrays Which array function checks if the specified key exists in the array? array_key_exist() array_key_exists() array_keys_exists() arrays_key_exists() array_key_exist() array_key_exists() array_keys_exists() arrays_key_exists() 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_slice ($fruits, 2);print_r ($subset); Array ( [0] => peach [1] => pear [2] => orange ) Array ( [0] => peach ) Array ( [0] => apple [1] => mango ) Array ( [0] => apple [1] => mango [2] => peach ) Array ( [0] => peach [1] => pear [2] => orange ) Array ( [0] => peach ) Array ( [0] => apple [1] => mango ) Array ( [0] => apple [1] => mango [2] => peach ) ANSWER DOWNLOAD EXAMIANS APP
PHP Arrays Absent any actual need for choosing one method over the other, does passing arrays by value to a read-only function reduce performance compared to passing them by reference? Yes, because the interpreter must always create a copy of the array before passing it to the function. Yes, because PHP must monitor the execution of the function to determine if changes are made to the array. Yes, but only if the array is large. No Yes, but only if the function modifies the contents of the array. Yes, because the interpreter must always create a copy of the array before passing it to the function. Yes, because PHP must monitor the execution of the function to determine if changes are made to the array. Yes, but only if the array is large. No Yes, but only if the function modifies the contents of the array. ANSWER DOWNLOAD EXAMIANS APP
PHP Arrays What will be the output of the following PHP code?$a=array("A","Cat","Dog","A","Dog");$b=array("A","A","Cat","A","Tiger");$c=array_combine($a,$b);print_r(array_count_values($c)); Array ( [A] => 2 [Cat] => 1 [Dog] => 4 [Tiger] => 1 ) Array ( [A] => 5 [Cat] => 2 [Dog] => 2 [Tiger] => 1 ) Array ( [A] => 6 [Cat] => 1 [Dog] => 2 [Tiger] => 1 ) Array ( [A] => 2 [Cat] => 2 [Dog] => 1 [Tiger] => 1 ) Array ( [A] => 2 [Cat] => 1 [Dog] => 4 [Tiger] => 1 ) Array ( [A] => 5 [Cat] => 2 [Dog] => 2 [Tiger] => 1 ) Array ( [A] => 6 [Cat] => 1 [Dog] => 2 [Tiger] => 1 ) Array ( [A] => 2 [Cat] => 2 [Dog] => 1 [Tiger] => 1 ) ANSWER DOWNLOAD EXAMIANS APP
PHP Arrays Assume you would like to sort an array in ascending order by value while preserving key associations. Which of the following PHP sorting functions would you use? krsort() asort() sort() usort() ksort() krsort() asort() sort() usort() ksort() ANSWER DOWNLOAD EXAMIANS APP