Diff. between abstract class and an interface
Printed From: One Stop GATE
Category: GATE Technical Discussions
Forum Name: GATE CS
Forum Discription: General Technical Discussions, Queries, doubts etc. for GATE in CS.
URL: http://forum.onestopgate.com/forum_posts.asp?TID=345
Printed Date: 27Aug2025 at 4:56am
Topic: Diff. between abstract class and an interface
Posted By: Priya
Subject: Diff. between abstract class and an interface
Date Posted: 15Feb2007 at 10:02am
What is diff. between abstract class and an interface? What is shadowing? Diff between Overriding and overloading?
Answer
An abstract class and Interface both have method only but not have
body of method.The difference between Abstract class and An Interface
is that if u call Ablstract class then u have to call all method of
that particular Abstract class but if u call an Interface then it is
not necessary that u call all method of that particular
interface.Method OverLoading:-Return type, Parameter type, parameter
and body of method number may be different.Method Overriding:- Return
type, Parameter type, Parameter Number all must be same . Only body of
method can change.
------------- For More Sample Papers Visit:
http://onestopgate.com/gate-preparation/ - http://onestopgate.com/gate-preparation/
|
|