CSE :: PHP - CS
-
What will be the output of the following PHP code ?
<?php
class myObject { }
define('myObject::CONSTANT', 'test');
echo myObject::CONSTANT;
?>
-
What will be the output of the following PHP code ?
<?php
$x = 5;
$y = 10;
$z = "$x + $y";
echo "$z";
?>
-
What will be the output of the following PHP code ?
<?php
$x = 4;
$y = 3;
$z = 1;
echo "$x = $x + $y + $z";
?>
-
What will be the output of the following PHP code ?
<?php
$x = 4;
$y = 3
$z = 1;
$z = $z + $x + $y;
echo "$z";
?>
-
What will be the output of the following PHP code ?
<?php
$x = 3.3;
$y = 2;
echo $x % $y;
?>
-
What will be the output of the following PHP code ?
<?php
$x = 10;
$y = 4;
$z = 3;
echo $x % $y % $z;
?>
-
What will be the output of the following PHP code ?
<?php
$x = 10;
$y = 4;
$z = 3;
echo ($x % ($y) + $z);
?>
-
What will be the output of the following PHP code ?
<?php
$x = 30;
$y = 20;
$z = 10;
echo $x + $y - $z / ($z - $y);
?>
-
What will be the output of the following PHP code ?
<?php
$x = 4;
$y = -3;
$z = 11;
echo 4 + $y * $z / $x;
?>
-
What will be the output of the following PHP code ?
<?php
$x = 3.5;
$y = 2;
$z = 2;
echo $x / $y / $z;
?>