0

Whats the difference between "public static void main()" and 'public static void main(String [ ] args)"??

Im a beginner

28th Jan 2019, 4:38 PM
Jyothish Krishna
Jyothish Krishna - avatar
2 Respostas
+ 8
String [] args is the command line arguments part. When command line arguments are passed then those are stored in that string args [] array
28th Jan 2019, 5:22 PM
Rstar
Rstar - avatar
+ 3
In the first case, you don't really care about the arguments being passed to your program. In the second case, they are stored in args.
28th Jan 2019, 5:55 PM
Zen
Zen - avatar