I am using IBM Websphere, and from here i can just click Run As java application, and the program runs inside websphere. But i want to run the program outside IDE.
I created a jar file and everthing is correct with it. It has the MANIFEST.MF and all.
So what do i need to do to run this from cmd.exe? I would like cmd to open when the jar file is double clicked so that the program will use the command line as the input?
import java.io.*; // Java I/O classes
public class L3P3
{
public static void main(String []arg) throws IOException // throws IOException
{
BufferedReader input = new BufferedReader(new InputStreamReader(System.in));
System.out.println("Enter in your full name");
String s1 = input.readLine();
StringBuffer tmp = new StringBuffer(s1);
String s2 = tmp.reverse().toString();
System.out.println("Your reversed name is " + "\"" + s2 + "\"");
}
}
Thanks, sj