11.07.2015 Views

PicC 9.50 dsPIC Manual.pdf

PicC 9.50 dsPIC Manual.pdf

PicC 9.50 dsPIC Manual.pdf

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Library FunctionsSTRLENSynopsis#include size_t strlen (const char * s)DescriptionThe strlen() function returns the number of characters in the string s, not including the null terminator.Example#include #include voidmain (void){char buffer[256];char * s1, * s2;}strcpy(buffer, "Start of line");s1 = buffer;s2 = " ... end of line";strcat(s1, s2);printf("Length = %d\n", strlen(buffer));printf("string = \"%s\"\n", buffer);Return ValueThe number of characters preceding the null terminator.206

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!