the code compiles with the latest compiler from sun
when I run the program I get the message
"main method not public"
I looked in jls 2.0 pg 235 under chap. 12.3.3 and it seems it is an Illegal Access Error.
Now the
java api says the following about it:
"Thrown if an application attempts to access or modify a field, or to call a method that it does not have access to.
Normally, this error is caught by the compiler; this error can only occur at run time if the definition of a class has incompatibly changed. "
So NORMALLY IT IS CAUGHT AT COMPILE TIME, so the answwer should be A
I did not found in the JLS any reference to the Main method signature, saying whta happens in diffrent situations.
Hope this helps...