+ 1

Why do we need" String array[]" ??

in the arguments if main() in java? pls ans ,thanks.

20th Jun 2017, 12:47 PM
MS Dhoni
MS Dhoni - avatar
2 Answers
+ 2
simply to store strings type data in array
20th Jun 2017, 2:40 PM
Prallab Rout
Prallab Rout - avatar
+ 1
Yes. Command line arguments are stored in this string array. For example when you execute your application: java app.jar -test "-test" can be used in the application to set a variable or other
20th Jun 2017, 1:26 PM
Louis
Louis - avatar