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

String s1=args[0];
String s2="";

for(int i=0; i<s1.length(); i++)
{
s2=s2+charAt(i);
}
if(s1.equals(s2))
System.out.println("Palindrome");
else
System.out.println("Not Palindrome");

Is This Answer Correct ?    168 Yes 173 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a pointer with example?

1154


Describe friend function & its advantages.

1090


What things would you remember while making an interface?

956


What is the use of 'this' pointer?

1209


What are multiple inheritances (virtual inheritance)? What are its advantages and disadvantages?

996


What is the advantage of c++ over c?

969


What is the difference between a "copy constructor" and an "assignment operator" in C++?

1020


Why is c++ a mid-level programming language?

967


How is new() different from malloc()?

1067


What is c++ prototype?

1082


Explain 'this' pointer and what would happen if a pointer is deleted twice?

1017


Is map sorted c++?

949


What is a responder chain?

1008


What is constant in c++ with example?

1078


How to declare a function pointer?

956