Answer Posted / narayanan
public class reverse {
public static void main(String args[]){
String s="malayalam";
StringBuffer sb=new StringBuffer();
int k=s.length();
for (int i = k-1; i >-1; i--) {
sb.append(s.charAt(i));
}
System.out.println(sb);
}
}
| Is This Answer Correct ? | 9 Yes | 0 No |
Post New Answer View All Answers
Where are global variables stored?
Is hashset ordered?
what methods would you overwrite in java.lang.object class?
How to use string tokenizer class.
Tell us something about set interface.
What is finalize()?
How do you sort words in java?
Explain spliterator in java8?
What's the difference between an abstract class and interface in java?
What is static synchronization?
What is the generic class?
How to split a string in java?
What is the diffrence between inner class and nested class?
What are decalarations?
Explain reverse a linked list recursive java solution?