C program check palindrome using function

#include<stdio.h>
#include<string.h>
char rev(str2)
{
char str1;
strrev(str2);
return (str2);
}
void main()
{
char str,a;
printf("enter the string");
gets(str);
 a=rev(str);
if(a==str)
printf("palindrome");
else
printf("not a palindrome");
getch();
clrscr();
}

Comments

Popular posts from this blog

Visti Cloud Service (VCS)

Being a DARK SKINNED is not a PROBLEM