Pattern_Wise_Reverse_Of_String_In_Cmd

public class Pattern_Wise_Reverse_Of_String_In_Cmd
{
public static void main(String args[])
{
if(args.length==1)
{
String s=args[0];
for(int i=0;i<s.length();i++)
{
s =s.substring(1)+s.charAt(0);
System.out.println(s);
}
}
else
{
System.out.println("wrong no of input");
}
}
}
RIGHT NOW A STUDENT..

No comments:

Post a Comment