Difference between abtsract & final



Difference between abtsract & final..

Answer / naveen

abstract and final are java modifiers. abstract is applied
to only class and methods.If class is abstract we cannot
instantiated of the class.If method is abstract it cannot
have body.abstract class contains concreate methods and
abstract methods.

final is a java modifier . It can be applied to class ,
variables, methods.If class is final we cannot inherited the
class. If variable is final we cannot change the value of
the variable. If method is final we cannot override that method.

Is This Answer Correct ?    14 Yes 0 No

Post New Answer

More Core Java Interview Questions

Difference between interface and abstract class with ex.

4 Answers   Cognizant, Tech Mahindra,


What is volatile data type?

0 Answers  


What is the arraylist in java?

0 Answers  


Why is static used?

0 Answers  


Can we convert stringbuffer to string?

0 Answers  






What will happen if there is a default method conflict as mentioned above and we have specified the same signature method in the base class instead of overriding in the existing class ?

0 Answers  


What is stringjoiner ?

0 Answers  


Can a main method be overloaded?

0 Answers  


How strings are created in java?

0 Answers  


What is the difference between stringbuffer and stringbuilder?

0 Answers  


Hi Friends, I am new to java. Can u explain about thread concept.How i know one thread is locked, and how can i force or acquire another thread for lock . Finally how to know thread is released from lock. Explain types of lock(like method level and block level) in thread.

1 Answers  


Why deletion in linkedlist is fast than arraylist?

0 Answers  


Categories