wes d2a2ba9e15 first commit | há 4 anos atrás | |
---|---|---|
.. | ||
README.md | há 4 anos atrás | |
code.cpp | há 4 anos atrás | |
unitTest.cpp | há 4 anos atrás |
by Matt tags: recursion, strings, language_fundamentals
Write a function that returns the length of a string. Make your function recursive. Examples length("apple") ➞ 5 length("make") ➞ 4 length("a") ➞ 1 length("") ➞ 0 Notes Check the Resources tab for info on recursion.
Write a function that returns the length of a string. Make your function recursive.
length("apple") ➞ 5
length("make") ➞ 4
length("a") ➞ 1
length("") ➞ 0
Check the Resources tab for info on recursion.