home *** CD-ROM | disk | FTP | other *** search
/ minnie.tuhs.org / unixen.tar / unixen / PDP-11 / Trees / V7 / usr / src / libc / gen / strlen.c < prev    next >
Encoding:
Text File  |  1979-01-10  |  158 b   |  16 lines

  1. /*
  2.  * Returns the number of
  3.  * non-NULL bytes in string argument.
  4.  */
  5.  
  6. strlen(s)
  7. register char *s;
  8. {
  9.     register n;
  10.  
  11.     n = 0;
  12.     while (*s++)
  13.         n++;
  14.     return(n);
  15. }
  16.