Whenever we create a method it is loaded in JVM(
Java Virtual Machine) in two main ways.
1. Static Methods 2. Non-Static Methods
1. Static Methods
In JVM, there is special memory allocated for Static members of a class (methods,variables,blocks,etc. which are marked as "static"). Whenever the class containing these methods is loaded in JVM, automatically these members are also loaded inside the JVM. So they are now existing in the system.
1. Non-Static Methods
In JVM, the members of a class which are not static , are not loaded automatically inside the JVM, but to load those we need to create object of that class. Once the object is created these methods are now existing in the system. Without object creation they do not exists.
Now you can imagine why it is needed an object to call a non static method.
As you can see, without object (non-static) methods or variables do not exists, then How can you call something which is not Existing.
But for Static members, they are loaded with class itself, not with Object, So you can call them without Object.
You can't call something that doesn't exist. Since you haven't created an object, the non-static method doesn't exist yet. A static method (by definition) always exists.
Static methods belong to the class; non-static methods belong to instances of the class