blob: 7aeb8d8319ca27eaabb82780268ba0895ff8111f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
#include <stdio.h>
/** write a string to stoud **/
int puts(const char *s)
{
if (fputs(s, stdout) == EOF) {
return EOF;
}
if (putc('\n', stdout) == EOF) {
return EOF;
}
/*
RETURN_SUCCESS(NONNEGATIVE());
RETURN_FAILURE(CONSTANT(EOF));
*/
return 1;
}
/***
function writes the string pointed to by ARGUMENT(s) to IDENTIFIER(stdout),
followed by a newline. The terminated CHAR(\0) is not written.
***/
/*
STDC(1)
*/
|