Question: Read strings fav _ fruit and least _ fav _ fruit from input. Output the following: ' My favorite fruit' followed by fav _ fruit,
Read strings favfruit and leastfavfruit from input. Output the following:
My favorite fruit' followed by favfruit, then 'has' followed by the length of favfruit, then 'characters', all separated by spaces.
My least favorite fruit' followed by leastfavfruit, then 'has' followed by the length of leastfavfruit, then 'characters', all separated by spaces.
Click here for example
Ex: If the input is:
banana
gourd
then the output is:
My favorite fruit banana has characters
My least favorite fruit gourd has characters
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
