public class Stuff {
public static final int MY_CONSTANT = 5;
public static int doStuff(int x){ return (x++)*x;}
}
import xcom.Stuff.*;
import java.lang.System.out;
class User {
public static void main(String[] args){
new User().go();
}
void go(){out.println(doStuff(MY_CONSTANT));}
}
Will the above code compile?
can be call a static method without mentioning the class name?