linkedin-skill-assessments-quizzes icon indicating copy to clipboard operation
linkedin-skill-assessments-quizzes copied to clipboard

[PHP] New question with answer

Open VIDAL-Antoine opened this issue 1 year ago • 1 comments

  • [x] New question

Question. What is the output of this script?

$believable = 'false';
$myth = 'The moon is made of green cheese';
$calc = 10**3+1;
if ($believable) {
    echo $myth;
}
else {
    echo $calc;
}
  • [ ] 10000
  • [ ] 31
  • [ ] 1001
  • [x] The moon is made of green cheese

Explanation : 'false' evaluates to true since it is a string so the if condition is met.

php-quiz

php-quiz-proof

VIDAL-Antoine avatar Dec 01 '23 16:12 VIDAL-Antoine

solved #6948

haxkd avatar Dec 02 '23 05:12 haxkd

Is this issue still open?

aaron-muti-420 avatar Jun 05 '24 14:06 aaron-muti-420