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 / prakash

#include<stdio.h>
#include<conio.h>

main()
{

char s1[10],s2[10];
int m,i,j;
scanf("%s",s1);
strcpy(s2,s1);
m=strlen(s1);
for(i=0,j=m-1;i<=m-1,j<=0;i++,j--)
{
if(s1[i]!=s2[j])
printf("STRING IS NOT PALINDROME ");
}
printf("STRING IS a PALINDROME ");
getch();
}

Is This Answer Correct ?    0 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain polymorphism?

1073


What is abstraction with real time example?

1146


Why are pointers used?

1002


What is the main purpose of overloading operators?

1132


What does scope resolution operator do?

1109


What is the difference between a reference and a pointer?

1105


What are keywords in c++?

1094


Can create new c++ operators?

1027


Difference between a copy constructor and an assignment operator.

999


Why cstdlib is used in c++?

1037


Which is best ide for c++?

1011


What is the difference between the functions memmove() and memcpy()?

1114


If dog is a friend of boy and boy is a friend of house, is dog a friend of house?

999


Define namespace in c++?

1043


What is == in programming?

1010