Advertisements
Advertisements
Question
What will be the output of the following PHP code?
<?php
for ($x = -1; $x < 10;--$x)
{
print $x;
}
?>Options
123456713910412
123456713910
1234567139104
Infinite loop
MCQ
Advertisements
Solution
Infinite loop
shaalaa.com
Looping Structure
Is there an error in this question or solution?
APPEARS IN
RELATED QUESTIONS
Which loop evaluates condition expression as Boolean, if it is true, it executes statements and when it is false it will terminate?
PHP supports which types of looping techniques ______.
List out Looping Structure in PHP.
Write Syntax of while loop in PHP.
Write Syntax of Do while loop in PHP.
Write the purpose of Looping Structure in PHP.
Differentiate For each and While loop.
Discuss in detail about Foreach loop.
Explain the process Do while loop.
Explain working of loops in array.
