← BYTES
Java·Starter·Ref: 9.1.7

What does the `static` keyword mean when applied to a method?

Have a question about this video? Mention reference 9.1.7 when you contact us.

a.The method is automatically private
b.The method cannot be overridden
c.The method runs only once per program
d.The method belongs to the class itself rather than to any one instance, and can be called without creating an object
A static method is associated with the class, not an instance -- it can be invoked as `ClassName.method()` with no object needed, and it cannot directly access instance (non-static) fields since there's no `this` to refer to.

Find this on YouTube & Instagram

Every BYTES video is tagged with its reference number and topic — search any of these on YouTube or Instagram to find this one:

#BYTES#BYTES917#Java