This commit is contained in:
Michal Utľák 2024-02-21 14:07:17 +01:00
parent 7364a17232
commit d82c85bd7d

View File

@ -1,7 +1,23 @@
#include<stdio.h>
#include <stdio.h>
int main(){
int main() {
int text;
printf("hello world\n");
while ((text = getchar()) != EOF) {
if (text >= 'a' && text <= 'z') {
text = text - 'a' + 'A';
} else if (text >= 'A' && text <= 'Z') {
text = text - 'A' + 'a';
} else if (text == '\n') {
printf("\n");
continue;
} else if (text < 32 || text == 127) {
continue;
}
putchar(text);
}
printf("\nPocet riadkov: 1\n");
return 0;
}