• HOME
  • QUIZ
  • CONTACT US
EXAMIANS
  • COMPUTER
  • CURRENT AFFAIRS
  • ENGINEERING
    • Chemical Engineering
    • Civil Engineering
    • Computer Engineering
    • Electrical Engineering
    • Mechanical Engineering
  • ENGLISH GRAMMAR
  • GK
  • GUJARATI MCQ

PHP Operators and Expressions

PHP Operators and Expressions
What will be the output of the following PHP code ?
$a = 5;
$b = -7;
$c =0;
$d = ++$a && ++$b || ++$c;
print $d;
print $a;

16
05
06
15

ANSWER DOWNLOAD EXAMIANS APP

PHP Operators and Expressions
What will be the output of the following PHP code ?
class myObject { }
define('myObject::CONSTANT', 'test');
echo myObject::CONSTANT;

error
myObject::CONSTANT
no output
test

ANSWER DOWNLOAD EXAMIANS APP

PHP Operators and Expressions
What will be the output of the following PHP code ?
$a = 'a';
print $a * 2;

error
192
2
0

ANSWER DOWNLOAD EXAMIANS APP

PHP Operators and Expressions
What will be the output of the following PHP code ?
function fun() {
static $x = 0;
echo $x;
$x++;
}
fun();
fun();
fun();

Error
012
123
111

ANSWER DOWNLOAD EXAMIANS APP

PHP Operators and Expressions
What will be the output of the following PHP code ?
$i = 1;
if ($i++ && ($i == 1))
printf("Yesn$i");
else
printf("Non$i");

No 1
Yes 2
Yes 1
No 2

ANSWER DOWNLOAD EXAMIANS APP

PHP Operators and Expressions
What will be the output of the following PHP code ?
$var1 = 3;
print ++$var++;

4
5
error
3

ANSWER DOWNLOAD EXAMIANS APP
MORE MCQ ON PHP Operators and Expressions

DOWNLOAD APP

  • APPLE
    from app store
  • ANDROID
    from play store

SEARCH

LOGIN HERE


  • GOOGLE

FIND US

  • 1.70K
    FOLLOW US
  • EXAMIANSSTUDY FOR YOUR DREAMS.
  • SUPPORT :SUPPORT EMAIL ACCOUNT : examians@yahoo.com

OTHER WEBSITES

  • GUJARATI MCQ
  • ACCOUNTIANS

QUICK LINKS

  • HOME
  • QUIZ
  • PRIVACY POLICY
  • DISCLAIMER
  • TERMS & CONDITIONS
  • CONTACT US
↑