write program for palindrome
Answer Posted / felix
#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();
}
| Is This Answer Correct ? | 242 Yes | 354 No |
Post New Answer View All Answers
Differences between private, protected and public and give examples.
State two differences between C and C++.
Write a program using display() function which takes two arguments.
What is the difference between an external iterator and an internal iterator? Describe an advantage of an external iterator?
If all is successful, what should main return a) 0 b) 1 c) void
Can comments be nested?
what is data encapsulation in C++?
Why do we use the using declaration?
What is a virtual destructor? Explain the use of it?
Why is "using namespace std;" considered bad practice?
Differentiate between a constructor and a destructor in c++.
Differentiate between an array and a list?
Is c++ the hardest language?
Can I learn c++ in a week?
What is the main function c++?