home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The C Users' Group Library 1994 August
/
wc-cdrom-cusersgrouplibrary-1994-08.iso
/
listings
/
v_10_10
/
1010024b
< prev
next >
Wrap
Text File
|
1992-09-01
|
294b
|
17 lines
#include <stdio.h>
#define MAXLINE 80
main()
{
int n;
char c, buf[MAXLINE+1];
while (gets(buf))
if (sscanf(buf,"%d , %c",&n, &c) == 2)
printf("%d, %c\n",n,c);
else
printf("Invalid input: \"%s\"\n",buf);
return 0;
}