#include<stdio.h>
#include<string.h>
main()
{
char a[5],b[5];
clrscr();
printf("Enter the character =");
scanf("%s",&a);
strcpy(b,a);
strrev(a);
if(strcmp(a,b)==0)
{
printf("String is palandrom");
}
else
printf("String is not palandrom");
getch();
}
By Dinesh Thakur
#include<stdio.h>
#include<string.h>
main()
{
char a[5],b[5];
clrscr();
printf("Enter the character =");
scanf("%s",&a);
strcpy(b,a);
strrev(a);
if(strcmp(a,b)==0)
{
printf("String is palandrom");
}
else
printf("String is not palandrom");
getch();
}
Dinesh Thakur is a Freelance Writer who helps different clients from all over the globe. Dinesh has written over 500+ blogs, 30+ eBooks, and 10000+ Posts for all types of clients.
For any type of query or something that you think is missing, please feel free to Contact us.