Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

why java not supproting multiple inheritance?

Answer Posted / tulasi prasad

java does not support multiple inheritance directly because


if we r deriving a sub class from 2 super classes which are
as follows

class A
{
void meth()
{
// substraction;
}
}

class B
{
void meth()
{
// Addition;
}
}

class C extends A,B
{
meth()<--- system get into confusion whether its add
or substarct.
}

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what r advatages of websphere? & how to deploy?

2256


What is parseint?

1068


What is ph and buffers?

1045


What's the base class of all exception classes?

1114


When would you use a static class?

1025


Who found java?

1021


What are accessor methods in java?

1049


What are the advantages of exception handling in java?

1099


What are different access specifiers in java?

1056


What is java and its types?

1163


What are the differences between wait() and sleep()?

1048


What is the difference between normal report & matrix report?

1156


Are global variables initialized to zero?

997


Which are the two subclasses under exception class?

1162


Can a java program have 2 main methods?

1092