something
This commit is contained in:
parent
9a2d9f07eb
commit
a00408d732
10
for.c
10
for.c
@ -13,12 +13,16 @@ int for_cyklus(){
|
|||||||
printf("Zadal si číslo %d.\n", target);
|
printf("Zadal si číslo %d.\n", target);
|
||||||
printf("Cyklus FOR:\n");
|
printf("Cyklus FOR:\n");
|
||||||
for(int i = 0; i <= target; i++){
|
for(int i = 0; i <= target; i++){
|
||||||
printf("%d\n", i);
|
if(i % 2 == 1) {
|
||||||
|
printf("%d\n", i);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
printf("Cyklus WHILE:\n");
|
printf("\nCyklus WHILE:\n");
|
||||||
int i = 0;
|
int i = 0;
|
||||||
while(i <= target){
|
while(i <= target){
|
||||||
printf("%d\n", i);
|
if(i % 2 == 1) {
|
||||||
|
printf("%d\n", i);
|
||||||
|
}
|
||||||
i++;
|
i++;
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user