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 / pallavi attarde

#include<iostream.h>
#include<string.h>

int main()
{
char str[25],str1[25];
cout<<"Enter a string: ";

gets(str);

strcpy(str1,str);
strrev(str);
if(strcmp(str,str1)!=0)
{
cout<<"string is not palindrome";
}
else
{
cout<<"string is a palindrome";
}

cout<<endl;

Is This Answer Correct ?    596 Yes 248 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain how the virtual base class is different from the conventional base classes of the opps.

1120


What do you mean by stack unwinding in c++?

1192


Write a program which uses functions like strcmp(), strcpy()? etc

1064


We all know that a const variable needs to be initialized at the time of declaration. Then how come the program given below runs properly even when we have not initialized p?

1047


Is c++ a good first language to learn?

1034


Explain the use of virtual destructor?

1040


Which programming language is best to learn first?

1025


What is c++ virtual inheritance?

1092


How does code-bloating occur in c++?

1154


What is private public protected in c++?

997


What is a class definition?

1033


Write a short code using c++ to print out all odd number from 1 to 100 using a for loop

989


List the features of oops in c++?

995


Define 'std'.

1138


What is c++ mutable?

1091