본문 바로가기

C

[C언어] 반복문(while)

반응형

다음으로 while조건식일 동안 반복한다.

 

#include<stdio.h>

int main(){

   int i = 1;

   while(i <= 10){
      printf("%d\n", i);
      i++;
   }

   return 0;
}

 

 

 

반응형