PHP MCQ - English
What will be the output of the following php code?
$num =
Home | Discussion Forum
Free Online Test
What will be the output of the following php code?
$num = "1";
$num1 = "2";
print $num+$num1;
?>
3
1+2
Error
12
Answer : A
Free Online Test
View More Related Question
1) We can use _________ to comment a single line?
2) Which of the below statements is equivalent to $add += $add ?
3) What will be the output of the following code?function track()
{
static $count = 0;
$count++;
echo $count;
}
track();
track();
track();
4) What will be the output of the following PHP code?$num = 10;
echo 'What is her age? n She is $num years old';
What is her age? n She is $num years old
What is her age? She is $num years old
What is her age? She is 10 years old
What is her age?n She is 10 years old
View Answer
5) What will be the output of the following PHP code?$a = "clue";
$a .= "get";
echo "$a";