+ 2

[java] main method overloding is beneficial for the program by any mean to us.

if java does not run the overloaded main method 1. why we able to overload the main method.

5th Apr 2018, 11:54 PM
Nitish kumar jha
Nitish kumar jha - avatar
4 Réponses
+ 8
main method overloading is possible in Java refer this code you can understand how to use that https://code.sololearn.com/cQf2q6uFIbSt/?ref=app
6th Apr 2018, 4:10 AM
GAWEN STEASY
GAWEN STEASY - avatar
+ 1
I don’t think it’s possible. Each program only needs one main method. There’s no reason to overload it and it will confuse the compiler if you try
6th Apr 2018, 2:25 AM
Ariela
Ariela - avatar
0
Ariela that's why I ask is any use of this concept.
6th Apr 2018, 2:37 AM
Nitish kumar jha
Nitish kumar jha - avatar