PHP while

Jmnote bot (토론 | 기여)님의 2020년 11월 2일 (월) 02:35 판 (봇: 자동으로 텍스트 교체 (-source +syntaxhighlight))

1 개요

PHP while
  • 특정 조건이 true인동안 반복하는 반복문

2 예시

$x = 1;
while($x <= 5) {
  echo "[$x]";
  $x += 1;
}
# [1][2][3][4][5]
$x = 1;
while($x <= 5):
  echo "[$x]";
  $x += 1;
endwhile;
# [1][2][3][4][5]

3 같이 보기

4 참고

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}