Question: MATLAB Function Name: kirbyCase Inputs: 1. (char) A sentence to be converted to kirby case Outputs: 1. (char) The sentence converted to kirby case Banned

MATLAB Function Name: kirbyCase Inputs: 1. (char) A sentence to be convertedMATLAB

Function Name: kirbyCase Inputs: 1. (char) A sentence to be converted to kirby case Outputs: 1. (char) The sentence converted to kirby case Banned Functions: strrep() Background: You might have heard of camel case, the naming convention typically used when naming variables and functions in MATLAB, but have you ever heard of kirby case? Probably not, since we just made it up! Function Description Write a function that converts a given phrase to kirby case according to the following rules 1. Remove all special characters and punctuation (everything except letters and spaces) 2. Capitalize all letters that occur at the end of a word, and make all other letters lowercase 3. If 'kirby' appears in the string with any capitalization, capitalize all its letters (KIRBY'). Remove all spaces from the sentence 4. Example: out-kirbyCase('I love kirbyCase!') out IlovEKIRBYcasE Notes: . "kirby' will always appear once in the sentence . kirby' may appear as part of another word and should still be in all uppercase. (ex. NoNkirbynonKIRBY' and 'kirBYiNg' KIRBYinG) Punctuation can appear anywhere in the sentence including at the end of a word, and in this case the last letter should still be capitalized Each word will be separated by at least one space The string will always begin with a letter

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!