write program for palindrome
Answer Posted / sowmya
#include,studio.h>
#include<conio.h>
void main()
{
int num,mod,rev=0;
clrscr();
printf("Enter any no:");
scanf("%d",&n);
while(n>=0)
{
mod=n%10;
rev=rev*10+mod;
n=n/10;
}
if(rev=n)
{
printf("palindrome");
}
else
{
printf("not palindrome");
}
}
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is the difference between #import and #include?
How do you clear a map in c++?
what are the events occur in intr activated on interrupt vector table
Explain about Garbage Collector?
What is function declaration in c++ with example?
What is c++ library?
Is c++ still in demand?
Difference between an inspector and a mutator
Is c++ a low level language?
What relational operators if statements in c++?
What is the difference between method overloading and method overriding in c++?
Will c++ be replaced?
When should I use unitbuf flag?
What is const pointer and const reference?
What is the purpose of the "delete" operator?