write program for palindrome
Answer Posted / dharm
#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==s)
printf("the no is palindrome");
else
printf("no is not palindrome");
getch();
}
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Which is best c++ or java?
Explain the difference between c++ and java.
How many types of scopes are there in c++?
What is iostream in c++ used for?
How do you flush a buffer in c++?
Can constructor be private in c++?
What is increment operator in c++?
What is a sequence in c++?
What is isdigit c++?
How do you decide which integer type to use?
Describe exception handling concept with an example?
What is the purpose of ios::basefield in the following statement?
What language does google use?
Can you please explain the difference between static and dynamic binding of functions?
What is & in c++ function?