PHP dasturlash tilida sikl operatorlari.
For, While, Do-While, For-each
Oddiy misollar orqali php da takrorlash operatorlarini ko'rsatib o'taman.
For sikl operatori:
for ($x = 0; $x <= 5; $x++) { echo "The number is: $x <br>"; }
While sikl operatori:
1; while($x <= 5) $x = { echo "The number is: $x <br>"; $x++; }
Do-While sikl operatori:
1; do $x = { echo "The number is: $x <br>"; $x++; } while ($x <= 5);
For-each sikl operatori:
array("3","2","1"); foreach ($x as $value) $x={ echo $value . " "; }
Comments
Post a Comment
Iltimos, fikrlaringizni yozib qoldiring !