The conversation between human and AI assistant.
What is the use of static keyword in Java?
Okay, I see. And what about the difference between static and non-static methods?
Well, the main difference is that non-static methods require an instance of the class to be created before they can be called, whereas static methods can be called directly on the class itself, without needing an instance. Another difference is that non-static methods have access to instance-level variables, whereas static methods can only access class-level variables.