pvjc22/du1/program.c

23 lines
339 B
C
Raw Normal View History

2022-03-03 20:55:42 +00:00
#include <stdio.h>
2022-03-03 21:23:08 +00:00
int main(){
int C = 0;
char Big_Wort;
int count = 0;
while(1){
C = getchar();
if(C == EOF)
break;
if(C == '\n')
count++;
if(C >= 'a' && C <= 'z')
C = C - 'a' + 'A';
else if(C >= 'A' && C <= 'Z')
C = C - 'A' + 'a';
Big_Wort = C;
putchar(Big_Wort);
}
2022-03-03 21:25:04 +00:00
printf("\nPočet riadkov: %d\n",count);
2022-03-03 21:23:08 +00:00
return 0;
}