home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Complete Linux
/
Complete Linux.iso
/
docs
/
apps
/
database
/
ingres04.lzh
/
source
/
gutil
/
length.c
< 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
C/C++ Source or Header
|
1985-01-23
|
296 b
|
24 lines
# include <sccs.h>
SCCSID(@(#)length.c 8.1 12/31/84)
/*
** FIND STRING LENGTH
**
** The length of string `s' (excluding the null byte which
** terminates the string) is returned.
*/
length(s)
char *s;
{
register int l;
register char *p;
l = 0;
p = s;
while (*p++)
l++;
return(l);
}