nerdexam
Zend

200-530 · Question #520

What will be the output of the following code snippet? <?php $a = 1; $b = 2; $c = 0xAF; $d = $b + $c; $e = $d * $b; $f = ($d + $e) % $a; print($f + $e); ?>

The correct answer is D. 354. Zend 200-530 Exam

PHP Basics

Question

What will be the output of the following code snippet? <?php $a = 1; $b = 2; $c = 0xAF; $d = $b + $c; $e = $d * $b; $f = ($d + $e) % $a; print($f + $e); ?>

Options

  • A200
  • BThe script will throw an error message
  • C0
  • D354

How the community answered

(40 responses)
  • A
    8% (3)
  • B
    15% (6)
  • C
    5% (2)
  • D
    73% (29)

Explanation

Zend 200-530 Exam

Topics

#hex literals#arithmetic operators#modulo#type casting

Community Discussion

No community discussion yet for this question.

Full 200-530 Practice