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...

can you program for reverse string?

Answer Posted / indumathi

public class StringReverseExample {

public static void main(String[] args)
{
String string=args[0];
String reverse = new StringBuffer
(string).reverse().toString();
System.out.println("\nString before
reverse:"+string);
System.out.println("String after
reverse:"+reverse);
}


}

Is This Answer Correct ?    9 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of optional ?

980


What are the 8 data types in java?

933


What carriage return means?

907


How is it possible for two string objects with identical values not to be equal under the == operator?

921


Difference between operator overloading and function overloading

1010


What is %d in printf?

989


What is the difference between class & structure?

1113


Is there any case when finally will not be executed?

899


Give some features of interface?

1014


Can we return null in java?

1062


What do you mean by garbage collection used in java?

1005


Can we call the run() method instead of start()?

981


Explain the use of sublass in a java program?

972


What is the difference between abstraction and encapsulation?

999


what is use of functional interface in java 8?

974