MCQOPTIONS
Bookmark
Saved Bookmarks
→
Php
→
Online Quiz in Php
→
Which of following variables can be assigned a val..
1.
Which of following variables can be assigned a value to it?
A.
$this
B.
$3hello
C.
$This
D.
$_hello
E.
Both C and D
Answer» F.
Show Answer
Discussion
No Comment Found
Post Comment
Related MCQs
What is the value of $a and $b after the function call?<br><pre class="prettyprint lang-c"><?php<br>function doSomething(&$argument) <br> {<br> $Result = $argument;<br> $argument += 1;<br> return $Result; <br> }<br>$n = 5;<br>$m = doSomething($n);<br>echo "n = " . $n . " and m = " . $m;<br>?><br></pre>
What will be the output of the following PHP code?<br><pre class="prettyprint lang-c"><?php<br>$user = array("Ats ", "Ajit ", "Rahul ", "Aju ");<br>for ($str=0; $str < count($user); $str++) {<br>if ($user[$str] == "Rahul ") continue;<br>printf ($user[$str]); <br>}<br>?><br></pre>
What will be the output of the following PHP code?<br><pre class="prettyprint lang-c"><?php<br>$math = "25 students";<br>$Science = 35;<br>$math = $math + $Science;<br>echo "$math";<br>?><br></pre>
What will be the output of the following PHP code?<br><pre class="prettyprint lang-c"><?php<br>$num = 10120;<br>$num1 = (array) $num;<br>echo $num1[0];<br>?><br></pre>
What will be the output of the following code?<br><pre class="prettyprint lang-c"><?php <br>$name = 'Ajit'; <br>$temp = &$name; <br>$temp = "My name is $temp. "; <br>echo $temp;<br>echo $name;<br>?><br></pre>
What will be the output of the following PHP code?<br><pre class="prettyprint lang-c"><?php<br>$var = "YELLOW";<br>$var1 = $var[5];<br>echo "$var1";<br>?><br></pre>
What will be the output of the following PHP code?<br><pre class="prettyprint lang-c"><?php<br>$State = "Chennai";<br>switch ($State) {<br>case "Mumbai":<br>echo "I love Mumbai. ";<br>case "Chennai":<br>echo "I love Chennai. ";<br>case "Rajshathan":<br>echo "I love Rajshatan. "; }<br>?><br></pre>
What will be the output of the following code?<br><pre class="prettyprint lang-c"><?php<br>function track() <br> {<br> static $var = 0;<br> $var++;<br> echo $var;<br> }<br> track();<br> track();<br> track();<br>?><br></pre>
What will be the output of the following PHP code?<br><pre class="prettyprint lang-c"><?php <br/>$n = 18;<br>echo 'What is her age? n She is $n years old.';<br>?><br></pre>
What will be the output of the following PHP code?<br><pre class="prettyprint lang-c"><?php<br>$num = 6;<br>$num1 = 6;<br>echo ($num === $num1);<br>?><br></pre>
Reply to Comment
×
Name
*
Email
*
Comment
*
Submit Reply