write program for palindrome
Answer Posted / felix
#include<stdio.h>
#include<string.h>
#define size 26
void main()
{
char strsrc[size];
char strtmp[size];
clrscr();
printf("\n Enter String:= ");
gets(strsrc);
strcpy(strtmp,strsrc);
strrev(strtmp);
if(strcmp(strsrc,strtmp)==0)
printf("\n Entered string \"%s\" ispalindrome",strsrc);
else
printf("\n Entered string \"%s\" is not
palindrome",strsrc);
getch();
}
Is This Answer Correct ? | 182 Yes | 97 No |
Post New Answer View All Answers
Explain the concept of memory leak?
What is stream and its types in c++?
Write a program using shift_half( ) function to shift the elements of first half array to second half and vice versa.
Is map ordered c++?
Why is c++ difficult?
What do you understand by pure virtual function? Write about its use?
How do you flush a buffer in c++?
What is dev c++ used for?
What is a storage class?
Can c++ do everything c can?
What is #include ctype h in c++?
How important is c++?
What is the difference between cin.read() and cin.getline()?
What is the best way to declare and define global variables?
What jobs can you get with a c++ certification?