What will happen when you attempt to compile and run this code?Explain your answer.
Public class MyMain {
Public static void main(String [] args){
System.out.println(“Hello cruel world”);
}
}
a) The compiler will complain that the class is not definedcorrectly.
b) The code will compile and when run will print out “Hellocruel world”.
c) The code will compile but will complain at run time that noconstructor is defined.
d) The code will compile but will complain at run time that themain method is not correctly defined.
Please note this is java.
Expert Answer
An answer will be send to you shortly. . . . .