Cody

# Problem 44499. Capitilize the first letter of every word in a string

Solution 1417147

Submitted on 15 Jan 2018 by shimon zusmanovsky
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

### Test Suite

Test Status Code Input and Output
1   Pass
sentence = 'this is BETTER than C++'; corrected = 'This Is Better Than C++'; assert(isequal(autoCase(sentence), corrected))

x = 'this is better than c++' x = 'This is better than c++' n = 23 x = 'This Is better than c++' x = 'This Is Better than c++' x = 'This Is Better Than c++' x = 'This Is Better Than C++' corrected = 'This Is Better Than C++'

2   Pass
sentence = 'hEy, tHis iS vErY wroNg!'; corrected = 'Hey, This Is Very Wrong!'; assert(isequal(autoCase(sentence), corrected))

x = 'hey, this is very wrong!' x = 'Hey, this is very wrong!' n = 24 x = 'Hey, This is very wrong!' x = 'Hey, This Is very wrong!' x = 'Hey, This Is Very wrong!' x = 'Hey, This Is Very Wrong!' corrected = 'Hey, This Is Very Wrong!'