write program for palindrome
Answer Posted / muhammad umair arif
#include <iostream>
using namespace std;
void main()
{
int a,b,c,d,e,f;
cout<<"Enter three digit "<<endl;
cin>>a;
b=a/100;
c=a%100;
d=c/10;
e=c%10;
f=e;
if(f==b)
{
if(d==d)
{
if (b==f)
{
cout<<"It is Palindrome "<<endl;
}
}
}
else
cout<<"It isnot Palindrome "<<endl;
}
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is c++ course?
How a modifier is similar to mutator?
How new/delete differs from malloc()/free?
Show the declaration for a pointer to function returning long and taking an integer parameter.
Explain container class.
What is the difference between #import and #include in c++?
Where are setjmp and longjmp used in c++?
What is the best c++ ide?
What does flush do?
What is prototype for that c string function?
How do you invoke a base member function from a derived class in which you’ve overridden that function?
Can the operator == be overloaded for comparing two arrays consisting of characters by using string comparison?
How do I start a c++ project?
What are compilers in c++?
What is else if syntax?