Created
July 31, 2018 14:23
-
-
Save yusureabc/33a82f54347b96791f8fc146d40ce8ae to your computer and use it in GitHub Desktop.
打印所有的 java 命令行参数
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* $ javac CommandLine.java | |
$ java CommandLine this is a command line 200 -100 */ | |
public class CommandLine | |
{ | |
public static void main(String[] args) | |
{ | |
int len = args.length; | |
for ( int i = 0; i < len; i++ ) | |
{ | |
System.out.println( args[i] ); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment