what is the difference between abstract class and
Interface?where we can use it in realtime projects?

Answer Posted / nanda

diff b/w abstract class and interface
1.Abstract class contain both normal fn as well as Abstract
fn wheras Interface can define only abstract fn.
2.by default declared variable in interface is static and
final.
in realtime projects we use inerfaces in AWT OR SWING,where
we implement the inerfaces and use them

Is This Answer Correct ?    30 Yes 12 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to Sort Strings which are given in List and display in ascending order without using java api.

3782


What is the driver class?

569


Which access specifier can be used with class ?

539


What is an 8 bit word?

598


If I don't provide any arguments on the command line, then what will the value stored in the string array passed into the main() method, empty or null?

715






What is static keyword in java?

556


Is arraylist sorted in java?

539


Can we write method inside a method in java?

530


What is the advantage of preparedstatement over statement?

572


What carriage return means?

534


What is file in java?

564


How do I run java on windows?

533


Is arraylist zero based?

559


What is meant by object?

583


How a variable is stored in memory?

507