Moved putchar to putchar.c
This commit is contained in:
parent
7a5099b1d8
commit
96e0e3d2f9
|
@ -0,0 +1,11 @@
|
|||
#include <stdio.h>
|
||||
|
||||
int puts(const char *s)
|
||||
{
|
||||
while(*s)
|
||||
if(fputc(*s++,stdout)==EOF)
|
||||
return EOF;
|
||||
if(fputc('\n',stdout)==EOF)
|
||||
return EOF;
|
||||
return 0;
|
||||
}
|
|
@ -9,7 +9,3 @@ int puts(const char *s)
|
|||
return EOF;
|
||||
return 0;
|
||||
}
|
||||
|
||||
int putchar(int c) {
|
||||
return fputc(c, stdout);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue