Friday, October 22, 2010

#2 for/while ciklusi stampanje imena 10 puta

#include<stdio.h>
#include<conio.h>

main(){

 int i=0;
 for (int i=0;i<10;i++){             // for ciklus
          printf("%d. Marko \n",i);
     }
    
printf("\n");

 while (i<10)                           //While ciklus
 {
      printf("%d. Marko \n",i);
      i++;  
 }    
 getch();     
}

No comments:

Post a Comment