National_Instruments
200-500 · Question #56
200-500 Question #56: Real Exam Question with Answer & Explanation
Sign in or unlock 200-500 to reveal the answer and full explanation for question #56. The question stem and answer options stay visible for context.
Question
What is the output of the following script? 1 <?php 2 function fibonacci (&$x1 = 0, &$x2 = 1) 3 { 4 $result = $x1 + $x2; 5 $x1 = $x2; 6 $x2 = $result; 8 return $result; 9 } 11 for ($i = 0; $i < 10; $i++) { 12 echo fibonacci() . ','; 13 } 14 ?>
Options
- AAn error
- B1,1,1,1,1,1,1,1,1,1,
- C1,1,2,3,5,8,13,21,34,55,
- DNothing
Unlock 200-500 to see the answer
You've previewed enough free 200-500 questions. Unlock 200-500 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.