200-710 Exam QuestionsBrowse all questions from this exam

200-710 Exam - Question 4


What is the output of this code?

Show Answer
Correct Answer: B

The code uses nowdoc syntax, which means the content inside TEXT will be treated as a plain string, and variables will not be parsed. Thus, the value of `$world` will not be interpolated into the string, and `hello $world` will be output literally.

Discussion

4 comments
Sign in to comment
Iamthebestboy
Mar 26, 2021

The answer is C, because as you can see, TEXT; has space from left side, and it gives a Parse Error

Jeffry
Oct 10, 2019

Answer should be B, has been tested.

Jeffry
Oct 18, 2019

Whoops! It's C explanation: $world = `world'; instead of $world = 'world';

nicky91294
Jun 27, 2021

Answer is B