#include <stdio.h>
#include <string.h>
int main() {
    char str[90];
    int i=0, l=0, c=0;
    printf("enter a string: ");
    scanf("%s",str);
    l=strlen(str);
    for (i=0;i<l/2;i++){
        if (str[i]==str[l-i-1]){
            c++;
        }
    }
    if (i==c){
        printf("\nit is a palindrome");
    }
    else{
        printf("\nit is not a palindrome");
    }
    return 0;
}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: