Exam 200-710 All QuestionsBrowse all questions from this exam
Question 24

What is the output of the following code?

    Correct Answer: D

    The given PHP code will produce an error. The variable $first has the value 'second', so $$first is equivalent to $second. However, $second is set to 'fisrt' instead of a valid variable. Therefore, echo $$first attempts to echo the value of a variable named 'fisrt', which has not been defined, leading to a notice about an undefined variable.

Discussion
[Removed]Option: D

if the value of the variable $second is correct and not a typo and "fisrt".. the output will be a "Notice : Undefined variable: fisrt"

Andres_Espinosa1Option: D

lo que genera el error son los signos pesos de mas en el echo ($$$first), si no hay error tipografico la respuesta seria un error