suppose we have one String s="india is my country"; now we
get the o/p "like country my is India". what is the logic?
Answer Posted / neeraj03
String[] x1=s.split(" ");
for( int x2=x1.length-1; x2 >= 0; x2-- )
{
System.out.print( x1[x2] );
System.out.print( " ");
}
| Is This Answer Correct ? | 6 Yes | 2 No |
Post New Answer View All Answers
what is reflection api? How are they implemented?
How does java handle integer overflows and underflows?
What is the java api?
Can we extract main method from another class?
What is the resourcebundle class?
What if I write static public void instead of public static void?
Are jvm’s platform independent?
What do you understand by casting in java language? What are the types of casting?
What is the first argument of the string array in main method?
What is the locale class?