Question
Create a C program in a single source file. Program will utilize gets() to accept an inputted character string and store it in an array
Create a C program in a single source file. Program will utilize gets() to accept an inputted character string and store it in an array string[]. Program will then store the same string in another array reverse_string[] in the reverse order. Program should compare the elements of both arrays with a "for loop". Program should then determine if the inputted character string is considered a palindrome by comparing each element of the two strings and output if the string is a palindrome as "____________ is a palindrome" or if string is not a palindrome as "___________________ is not a palindrome".
sample:
Please enter a string: lolol
lolol is a palindrome.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started