0

what output results from the following code?

$x=0; while($x<=7){ $x++; } echo $x

16th Nov 2020, 8:51 PM
Sohila
Sohila - avatar
2 Respuestas
+ 1
8 From $x=0 to 7 condition true so last When 7<=7 true so $x++ executed so $x becomes 8 Condition fails when 8<=7, output 8
16th Nov 2020, 9:48 PM
Jayakrishna 🇮🇳
0
7
16th Nov 2020, 9:02 PM
KAWOTTE
KAWOTTE - avatar