Đ Đinh Yến New member Sep 20, 2021 #1 What will be the output of the following PHP code? Code: <?php for ($x = 0; $x <= 10; print ++$x) { print ++$x; } ?> A. 123456789101112 B. 12345678910 C. 1234567891011 D. infinite loop
What will be the output of the following PHP code? Code: <?php for ($x = 0; $x <= 10; print ++$x) { print ++$x; } ?> A. 123456789101112 B. 12345678910 C. 1234567891011 D. infinite loop
Q Quang Hiếu New member Sep 20, 2021 #2 Answer: a Explanation: The value of x is incremented and printed twice before checking,this last loop it prints 11 and 12. Upvote 0 Downvote
Answer: a Explanation: The value of x is incremented and printed twice before checking,this last loop it prints 11 and 12.