home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Resource for Source: C/C++
/
Resource for Source - C-C++.iso
/
codelib8
/
v_10_10
/
1010018b
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
Macintosh to JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
Text File
|
1995-11-01
|
242 b
|
16 lines
Listing 7 -- the file strcpy.c
/* strcpy function */
#include <string.h>
char *(strcpy)(char *s1, const char *s2)
{ /* copy char s2[] to s1[] */
char *s = s1;
for (s = s1; (*s++ = *s2++) != '\0'; )
;
return (s1);
}