Last active
May 5, 2016 22:04
-
-
Save jlgarridol/b0222cb4d0b9385da0a32b782dccb3cb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*prototype*/ | |
size_t stringlength(char[]); | |
/*funcion*/ | |
/** | |
*Title: stringlength | |
*Description: A implementation to calculate string length when the return of strlen don't work correctly | |
*@param chain[] - string which will be calculate length | |
*@return i - a lenght of stringlenght | |
*@author: José Luis Garrido Labrador (JoseluCross) from JKA Network <contacto@jkanetwork.com> | |
*@date: 05/05/2016 | |
*Licence: Apache 2.0 | |
*/ | |
size_t stringlength(char chain[]) { | |
size_t i; | |
for(i = 0; chain[i] != '\0'; ++i) ; | |
return i; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment