answersLogoWhite

0

int main(int argc, char* argv[])

{

char a[10],b[10];

printf("enter any string\n");

scanf("%s",a);

printf("a=%s",a);

strcpy(b,a);

strrev(b);

printf("\nb=%s",b);


if(strcmp(a,b)==0)

printf("\nstring is palindrome");

else

printf("\nnot pelindrome");

return 0;

}


User Avatar

Wiki User

12y ago

What else can I help you with?

Related Questions

Write a PHP program to check whether the string is palindrome or not?

You can do this: <?php if ( $word === strrev( $word ) ) { echo "The word is a palindrome"; } else { echo "The word is not a palindrome"; }


How do you write a palindrome program in c in Wikipedia?

You don't have to write palindrome programs in wikipedia.


How do you write palindrome program in c language?

int pallindrom(int p){ /*write all logic*/ }


How do you write a program in C to check whether a word is a palindrome or not?

It is a simple program. i think u may understand it :#include#include#includevoid main(){char s[10]=answers.com;char x[10];int a;clrscr();strcpy(x,s);strrev(s);a=strcmp(s,x);if(a==0){printf("the entered string is palindrome");}else{printf("the entered string is not palindrome");}output:given string is not palindrome


Write a program that allows the user to input a word or phrase and then determine if its a palindrome. I need to use a Boolean equals valued Function procedure names IsPalindrome. How?

forward(word) backward(word)


Where do we write main function in a c program?

Into the source program.


Using Python write an algorithm that takes a string as input and determines whether or not it is a palindrome?

def isPalindrome(s): return s == s[::-1] then just call the function with a string like isPalindrome('poop')


Write c program to print palindrome using string without using strrev strlen strcam?

sdfdg


Write a program using method plainto check whether a string is a palindrome or not A palindrome is a string that reads the same from left to right and vice-versa?

Palindrome number is a number like 121 which remains the same when its digits are reversed. To find this number in a simple java program, just follow the below way. sum = 0; while(n>0) { r=n % 10; sum=concat(r); n=n / 10; } print r;


Write programs for String Reversal and Palindrome check?

Write your program and if you are having a problem post it here with a description of the problem you are having. What you are asking is for someone to do your homework for you.


Write a program that read phrase and print the number of lower-case letter in it using function of counting?

write a program that reads a phrase and prints the number of lowercase latters in it using a function for counting? in C program


Write a program By using if else statement to read a number and check whether it is positive or negative?

write a c++program by using if statement to read a number and check whether it is positive or negative