#include<stdio.h>
main()
{
    char s[100];
    int i,j,l;
    printf("enter a string");
    gets(s);
    l=strlen(s);
    i=0;
    j=l-1;
    while(i<=j)
    {
        if(s[i]!=s[j])
        {
            break;
        }
        i++;
        j--;
    }
    if(i>=j) {
        printf("given string is a palindrome");
    }
    else
    {
        printf("given string is not a palindrome");
    }
}
     
           
Note: Need to be arranged in compiler after copied
   

 OutPut:

enter a string malayalam given string is a palindrome