In C, strings are terminated by a null character '\0'. Your task is to implement a custom strlen() function that calculates the length of a string without using any built-in functions.
You will be given a string of maximum of 100 characters. Return the number of characters before the null terminator.