write program for palindrome
Answer Posted / anonymous
#include<stdio.h>
#include<conio.h>
int main()
{
int n,s=0,m,r;
printf("enter any no");
scanf("%d",&n);
m=n;
while(n>0)
{
r=n%10;
s=s*10+r;
n=n/10;
}
if(m==s)
printf("the no is palindrome");
else
printf("no is not palindrome");
getch();
return 0;
}
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
In what situations do you have to use initialization list rather than assignment in constructors?
Is java the same as c++?
What are the types of array in c++?
What are default parameters? How are they evaluated in c++ function?
If there are two catch statements, one for base and one for derived, which should come first?
What is the use of c++ programming language in real life?
Explain rethrowing exceptions with an example?
How can you quickly find the number of elements stored in a a) static array b) dynamic array ? Why is it difficult to store linked list in an array?how can you find the nodes with repetetive data in a linked list?
Describe private, protected and public?
How do you sort a sort function in c++ to sort in descending order?
How do I use arrays in c++?
What is the latest version on c++?
Why is c++ so fast?
What is boyce codd normal form in c++?
What is a class template in c++?