What will be the output of the following PHP code ?
<?php
$age = array("Harry" => "21", "Ron" => "19", "Malfoy" => "23");
ksort($age);
foreach($age as $x => $x_value)
{
echo "Key=" . $x . ", Value=" . $x_value;
echo "<br>";
}
?>
- Key = Harry, Value = 21 Key = Ron, Value = 21 Key = Malfoy, Value = 23
- Key = Harry, Value = 21 Key = Ron, Value = 19 Key = Malfoy, Value = 23
- Key = Harry, Value = 21
Key = Malfoy, Value = 23
Key = Ron, Value = 19
- Key = Ron, Value = 19 Key = Harry, Value = 21 Key = Malfoy, Value = 23
(c).Key = Harry, Value = 21
need an explanation for this answer? contact us directly to get an explanation for this answerKey = Malfoy, Value = 23
Key = Ron, Value = 19