Answer: We access static methods or static variables from within static and non-static class with class name directly.Means no need to create object of class and access method.
Class_name.Method_name();
Class_name.Variable_name();
Asked In: Many Interviews |
Alert Moderator