*write a function that determines the length of the longest * word at the start
ID: 3610796 • Letter: #
Question
*write a function that determines the length of the longest* word at the start of string s * For the purposes of this problem, a word is a sequenceof *consecutive letters. You may use the isLetterfunction *if you'd like. * if the first character in s is not a letter, then thelength *of the word at the start of s is zero (i.e., s doesnot *start with a word). *for example *the length of the word at the start of "apple pie" is5 *the length of the word at the start of "40 acres" iszero *(since 4 is not a letter).
int startWordLenRec(char s[]){ } we are passed a string as the examplesays above any help would beappreciated this is our isLetter function that we aregiven to decide between letter and not int isLetter(char c){ if ('A' <= c && c<= 'Z') { return true; } else if('a' <= c&& c <= 'z') { return true; } else { return false; }
} *write a function that determines the length of the longest
* word at the start of string s * For the purposes of this problem, a word is a sequenceof *consecutive letters. You may use the isLetterfunction *if you'd like. * if the first character in s is not a letter, then thelength *of the word at the start of s is zero (i.e., s doesnot *start with a word). *for example *the length of the word at the start of "apple pie" is5 *the length of the word at the start of "40 acres" iszero *(since 4 is not a letter).
int startWordLenRec(char s[]){ } we are passed a string as the examplesays above any help would beappreciated this is our isLetter function that we aregiven to decide between letter and not int isLetter(char c){ if ('A' <= c && c<= 'Z') { return true; } else if('a' <= c&& c <= 'z') { return true; } else { return false; }
} } we are passed a string as the examplesays above any help would beappreciated this is our isLetter function that we aregiven to decide between letter and not int isLetter(char c){ if ('A' <= c && c<= 'Z') { return true; } else if('a' <= c&& c <= 'z') { return true; } else { return false; }
}