25 lines
403 B
C
25 lines
403 B
C
|
#include <stdio.h>
|
||
|
|
||
|
#define IN 0
|
||
|
#define OUT 1
|
||
|
|
||
|
void main()
|
||
|
{
|
||
|
int c, state = OUT;
|
||
|
|
||
|
while ((c = getchar()) != EOF) {
|
||
|
if (c == ' ' || c == '\n' || c =='\t') {
|
||
|
if (state == IN) {
|
||
|
putchar('\n');
|
||
|
state = OUT;
|
||
|
}
|
||
|
continue;
|
||
|
}
|
||
|
|
||
|
putchar(c);
|
||
|
state = IN;
|
||
|
}
|
||
|
if (state == IN)
|
||
|
putchar('\n');
|
||
|
}
|