Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

write program for palindrome

Answer Posted / aravindhan.d

// r=reminder,s=sum,n=number.
#include<stdio.h>
#include<conio.h>
void main()
{
int n,m,r,s=0;
clrscr();
printf("Enter the n value:");
scanf("%d",&n);
m=n;
while(n>0)
{
r=n%10;
s=s*10+r;
n=n/10;
}
if(m==s)//THIS SAME CODE IS GIVEN ABOVE BUT ONE CHANGE NOT m==n THAT IS m==s
{
printf("NUMBER IS PALINDROME");
}
else
{
printf("NUMBER IS NOT PALINDROME");
}

Is This Answer Correct ?    19 Yes 9 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is extern c++?

969


Does c++ vector allocate memory?

964


What are the advantages of using const reference arguments in a function?

1043


Why Pointers are not used in C++?

1043


What is isdigit c++?

1078


Explain the difference between c++ and java.

1077


How the keyword struct is different from the keyword class in c++?

1000


Why is swift so fast?

1078


How does c++ structure differ from c++ class?

1075


What is the use of ::(scope resolution operator)?

1044


What is meant by forward referencing and when should it be used?

966


What is time h in c++?

1101


What function initalizes variables in a class: a) Destructor b) Constitutor c) Constructor

1116


Are there any special rules about inlining?

1040


Why is c++ considered difficult?

1109