Question: Write a Python function that gets a string as parameter and (a) adds 'ing' at the end of the given string, (b) if the

Write a Python function that gets a string as parameter and (a) adds 'ing' at the end of the given string,

Write a Python function that gets a string as parameter and (a) adds 'ing' at the end of the given string, (b) if the given string already ends with 'ing' then add 'ly' instead. If the length of the given string is less than 3, it is unchanged. Note: Your solution must handle different case types (both uppercase and lowercase characters). Write Python statements that reads a string, calls the method and prints the result. Part-3: Please enter a string: test The output of the function is: testing Please enter a string: TESTING The output of the function is: TESTINGLY Please enter a string: Go The output of the function is: Go Write a Python function that gets a string as parameter and (a) adds 'ing' at the end of the given string, (b) if the given string already ends with 'ing' then add 'ly' instead. If the length of the given string is less than 3, it is unchanged. Note: Your solution must handle different case types (both uppercase and lowercase characters). Write Python statements that reads a string, calls the method and prints the result. Part-3: Please enter a string: test The output of the function is: testing Please enter a string: TESTING The output of the function is: TESTINGLY Please enter a string: Go The output of the function is: Go

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Heres a Python function that fulfills the requirement python def manip... View full answer

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 Computer Network Questions!