-
3 Comments
In addition to vowels, the second test also removes a space. While it's natural to want to clean up extra spaces, spaces are _not_ vowels.
The display of the test suite show the second space at the "I" being removed, but the actual test does not remove it. This is very confusing, but the test actually works as you would expect. It is just that the displayed "correct" answer is - in fact - not correct as you noted.
I had trouble with this as I saw your answer and accommodated their "error" in my solution. Except their error was only a display error and not an actual error in the test suite. Doh!
See https://www.mathworks.com/matlabcentral/cody/problems/22-remove-the-vowels/solutions/1218453 for a repaired version of your solution.
Of course I just noted that your solution is five months old, so you certainly won't care by now. C'est la vie.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!