PHP Arrays
Which function returns an array consisting of associative key/value pairs?

array_count()
array_count_values()
count()
count_values()

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 )
Array ( [0] => apple [1] => mango [2] => peach )
Array ( [0] => peach [1] => pear [2] => orange )
Array ( [0] => apple [1] => mango )

ANSWER DOWNLOAD EXAMIANS APP

PHP Arrays
What will be the output of the following PHP code ?
$a1 = array("a" => "red", "b" => "green", "c" => "blue", "d" => "yellow");
$result = array_flip($a1);
print_r($result);

Array ( [a] => a [b] => b [c] => c [d] => d )
Array ( [red] => red [green] => green [blue] => blue [yellow] => yellow )
Array ( [red] => a [green] => b [blue] => c [yellow] => d )
Array ( [a] => red [b] => green [c] => blue [d] => yellow )

ANSWER DOWNLOAD EXAMIANS APP