In Java, invoking methods depends on whether they are static or non-static (instance) methods.
=> Static methods are invoked using the class name without creating an instance:
=> Non-static methods are invoked using an instance of the class:
=> Static methods are invoked using the class name without creating an instance:
ClassName.methodName().
=> Non-static methods are invoked using an instance of the class:
objectName.methodName()
🔥1
Exam Q Code.txt
3.7 KB
Hello Everyone, This is draft answer key for the work out part. its just for your reference.