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 / sanam baig

#include<stdio.h>
#include<conio.h>
void main()
{
int n,s=0,m,r;
clrscr();
printf("enter any no");
scanf("%d",&n);
m=n;
while(n>0)
{
r=n%10;
s=s*10+r;
n=n/10;
}
if(s == m) // This is important step
printf("the no is palindrome");
else
printf("no is not palindrome");
getch();
}

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why do we use iterators?

1034


Describe private, protected and public – the differences and give examples.

1144


Describe linkages and types of linkages?

956


What is the prototype of printf function?

1133


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

1041


What is const pointer and const reference?

1105


What is #include ctype h in c++?

1131


What language is a dll written in?

989


What is the fastest c++ compiler?

1054


Differentiate between the manipulator and setf( ) function?

1128


Differences between private, protected and public and give examples.

1021


What are different types of loops in c++?

1093


What is a list c++?

1084


Why do we need templates?

959


Will a catch statement catch a derived exception if it is looking for the base class?

973