answersLogoWhite

0

C program for palindrome

User Avatar

Wiki User

11y ago

Best Answer

#include<stdio.h> #include<conio.h> void main() { int n,s=0,m; clrscr(); printf("enter any no"); scanf("%d",&n); m=n; while(n>0) { r=n%10; s=s*10+r; n=n/10; } if(m==n) printf("the no is palindrome"); else printf("no is not palindrome"); getch(); }

User Avatar

Wiki User

11y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: C program for palindrome
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

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

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


Stack c language program of palindrome?

what ever you assume


How do you write palindrome program in c language?

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


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

sdfdg


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


What is palindrome in c?

char* = "racecar"


What is the palindrome in c language?

Nothing.


Program to check that given string is palindrome or not in C?

/*To check whether a string is palindrome*/includeincludevoid main () { int i,j,f=0; char a[10]; clrscr (); gets(a); for (i=0;a[i]!='\0';i++) { } i--; for (j=0;a[j]!='\0';j++,i--) { if (a[i]!=a[j]) f=1; } if (f==0) printf("string is palindrome"); else printf("string is not palindrome"); getch (); }


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

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


Is a cow a palindrome?

The word 'cow' is not a palindrome because it is not spelled the same backward and forward (c-o-w, w-o-c).


Program to find palindrome using C programming?

#include&lt;stdio.h&gt; #include&lt;conio.h&gt; #include&lt;string.h&gt; void main() { char a[15],b[15]; printf("Enter the string\n"); scanf("%s",&amp;a); strcpy(b,a); strrev(a); if(strcmp(a,b)==0) printf("The String is a palindrome"); else printf("The String is not a palindrome"); }


Write a Program in c to find palindrome numbers between any two numbers?

please somebody should help me answer this question..I have a project on it even! It seems almost impossible at the moment.