Question: Write a program that takes one word and prints its palindrome. You can use the for loop, the strlen function, and the %s format in

Write a program that takes one word and prints its palindrome. You can use the for loop, the strlen function, and the %s format in scanf and print. You can use a new variable or one declared earlier for holding the reversed value of a word. Declare a string big enough to hold long words. For the record, you should use fgets instead of scanf in the future, especially when you want to have long strings with spaces.

Example

Input : book

output: koob

Use

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!