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

String Reverse in Java...!

Answer Posted / soumya roy

public class rev
{

public static void main(String[] args)
{
String str="hi my name is hello ";
System.out.println("the string is :" + str);
char[] ch=str.toCharArray();
int i;
int len = ch.length;
for(i=len-1;i>=0;i--)
{
System.out.print(ch[i]);
}
}
}

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What happens if we override private method?

924


Explain how hashmap works?

1021


Highest level event class of the event-delegation model?

3965


What is the purpose of extern variable?

969


How do you sort arrays in java?

890


What is the public method modifier?

965


Why pointers are not used in java?

1066


What is the purpose of using javap?

1051


What are methods in java?

953


Why parameters should be passed by reference?

923


How do you allocate memory to object?

934


What is binary search in java?

950


What is array command?

1111


What are the differences between Java 1.0 and Java 2.0?

2220


what is recursion in java

1096