mirror of
https://gitlab.gwdg.de/j.hahn02/university.git
synced 2026-01-01 14:54:25 -05:00
23 lines
400 B
C
23 lines
400 B
C
#include<stdio.h>
|
|
#include<ctype.h>
|
|
#include<string.h>
|
|
|
|
int main() {
|
|
char s[161], m1[161], m2[161];
|
|
int c1 = 0, c2 = 0;
|
|
|
|
fgets(s, sizeof(s), stdin);
|
|
|
|
for (int i = 0; i < strlen(s); i++) {
|
|
if (isalpha(s[i])) {
|
|
if (isupper(s[i])) {
|
|
m1[c1++] = s[i];
|
|
} else m2[c2++] = s[i];
|
|
}
|
|
|
|
}
|
|
printf("Nachricht an Toni: %s\n", m1);
|
|
printf("Nachricht an Tomke: %s\n", m2);
|
|
|
|
}
|