Can we call main method inside main?
public static void main(String[] args) {
main({"a","b","c"});
}
Tried to google.Can't find the link. Sorry if the question is trivial
You can but using the correct format
main(new String[] {"a","b","c"});
should give StackOverFlowError (not tested)
You will get StackOverFlowError
. If you call endless recursive calls/deep function recursions.
Thrown when a stack overflow occurs because an application recurses too deeply.
You need to pass String array like
main(new String[] {"a","b","c"});
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With