what is difference between class and object?

Answer Posted / revansiddappa p.h.

Class:
Is another kind of data type in oops like structure.
It is static in nature during program execution.

Object:
It is like variable of type class for accessing member
variables and methods.
Objects are dynamic in nature during program execution.
Can be constructed and destroyed.

Is This Answer Correct ?    44 Yes 14 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a numeric literal?

769


What is null in java?

720


What is a condition in java?

728


Why do we need hashset in java?

750


Can a class have multiple subclasses?

832


Can subclass overriding method declare an exception if parent class method doesn't throw an exception?

780


Difference between method overloading and overriding.

812


How variables are declared?

756


Which is easier netbeans or eclipse?

830


What are green threads in java?

770


If an object is garbage collected, can it become reachable again?

792


Write a program to print 15 random numbers using foreach of java 8?

759


How we can run a jar file through command prompt in java?

743


what is object slice?

1781


What are examples of modifiers?

738