Question: The code should be in C language and please use string functions only to reverse the sentence. Thank you Write a function: void reverse(char line,

 The code should be in C language and please use stringThe code should be in C language and please use string functions only to reverse the sentence. Thank you

Write a function: void reverse(char line, char reversed) that takes data a line at a time and reverse the words of the line. For example, Using the reverse function, write a program which, in a loop: 1. Prompts user to enter a line and reads it from input 2. Passes the string to function reverse 3. Prints out the reversed line 4. Prompts the user to "do another" by typing "y", or to quit the program by typing anything else. Sample output: Enter a line: birds and bees The reverse is: bees and birds. Do Another (y)?y Enter a line: Hello World The reverse is: World Hello Do Another (y)?n Press any key to continue

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!