Search

Java Program to print reverse of a string

public class StringReverse
{
  public static void main(String[] args)
   { 
     String s= (args[0]);
     for (int i =s.length()-1; i >= 0; i--)
      { 
        System.out.print(s.charAt(i));
       }
    }
 }

1 comment:

Anonymous said...

Hi there! I'm at work browsing your blog from my new iphone 3gs! Just wanted to say I love reading through your blog and look forward to all your posts! Carry on the fantastic work!

my page :: Discreetphysici13.Postbit.Com