Question: 4 . Add the Remaining Test Cases Just because one test case worked does not mean that the function is correct. The function has _

4. Add the Remaining Test Cases
Just because one test case worked does not mean that the function is correct. The function has_a_vowel can be "true in more than one way". For example, it is true when s has just one vowel, like the "a". Alternatively, s could be o or "e".
In the activity Designing Test Cases, you were tasked with coming up with several test cases for has_a_vowel. Add all of those to the test script, following the general formula:
Call the function has_a_vowel on the input for the test case.
Store the result of that function call in a variable called result.
Use introcs.assert_equals to compare result to the test case output.
You should have 10 test cases (including the one for string aeiou) when you are done. Before continuing on, you may wish to check that you did this correctly.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!