a) \r
b) \n
c) /n
d) /r
Answer: b
Explanation: PHP treats \n as a newline character.
Related Posts
Which function should we use to sort the array in natural order?
What will be the output of the following PHP code?
<?php
$arr = array (“picture1.JPG”, “picture2.jpg”, “Picture10.jpg”, “picture20.jpg”);
sort($arr);
print_r($arr);
?>What will be the output of the following PHP code?
<?php
$fruits = array (“mango”, “apple”, “peach”, “pear”);
$fruits = asort ($fruits);
printr ($fruits);
?>Which of the functions is used to sort an array in descending order?
What will be the output of the following PHP code?
<?php
$fruits = array (“mango”, “apple”, “pear”, “peach”);
$fruits = array_flip($fruits);
echo ($fruits[0]);
?>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>”;
}
?>What will be the output of the following PHP code?
<?php
$array = array(“red”, “green”);
array_push($array, “blue”, “yellow”);
print_r($array);
?>
Join The Discussion