0

Why main method in java takes only an array of String as its parameter?

Why main method in java takes specifically only an array of String as its parameter?

28th Jul 2019, 7:10 PM
scientist
scientist - avatar
3 ответов
+ 2
Useing an array allows you to pass multiple argument. Using Strings allows you to easily represent data of almost any data type. Using a String array allows you to pass multiple argument, each of which can represent data of almost any data type.
28th Jul 2019, 9:18 PM
josh mizzi
josh mizzi - avatar