why we need abstract class in java, what is the diff b/w
abstract claas in c++ and abstract class in java
Answer Posted / nikhil naoghare
Abstact classses are those classes which can have abstact as well as Common methods. we use Abstract classes because we want to implement Polymorphism.
Its always good to prefer the abstract class because it will give us the addtional method declaration in the class.
We use Abstract class to enforce some rules to the classes which extends it. For example we can define a class say Car and we can declare methods say Color() Mileage(). This means whatever the class that is derived from Car has to override or give definition for Color() and Mileage() and therefore we are making sure that all the derived classes follows or has the common functionalities. In other way the classes derived from superclass should have common properties. In addition to this the derive class can have its own methods like Type().
In case of Abstract class we can define COMMON functionalities in super class and those can be used in the derived class where as in Interface we cant do that.
Is This Answer Correct ? | 11 Yes | 3 No |
Post New Answer View All Answers
what books to prepare for atc please
hi i am avinash ,i am doing ma b-tech(cse) final year and i have been detained for 2years due to attendance and i will be finished ma b-tech in 6 years ,plz tell me weather i will be eligible for government jobs like bhel, drdo,or any other private companies
explain software engineering practices
who to change a passward in router?
WHERE CAN I GET SQL SERVER NOTES SOFT COPY?
What is Campus selection process of patni at Adcet,Ashta at 24th dec 2010.Also give apti syllabus.
what do you mean by CPU register?
hi friends, i got selected in tcs, i m doing my b.e in one of the college in coimbatore.. i don have questions to post u.. but i have valid suggestion..its waste to prepare apti for tcs by looking at last 10 year question from internet.they changed all the apti question this year(2009).. but apti questions is easy..prepare critical reasoning for gre 12th edition..mug up the answers in critical reasoning.. u can download ebook for gre 12th edition..solve the critical reasoing question at the same time mug up it.. there were totally 3 critical reasoning question asked.. two for gre 12th edition so if u mug up u can finish two questions in 3 min.. so u will have 27 min for other question so u can work it out and find the ans..above i mentioned as 3 questions tat is 3 question means ,three paargraph.. each para carries 4 question so totally 12 question in critical reasoning.. if u clear all 12 question u will be selected.80% percent sure.then don mug up synonyms from gre barron because they are asking same question from barron but the choice for the questions are changed.. so study synonyms and antonyms from internet.. some pupils have posted the questions.. in tech and h r don use complex word or don show tat u r so dminant.. talk with them how u will speak wit ur friend. u will be through.. don think wat i have posted above is lik some info in other site.. wat i said is true.. they changed apti tis time.. u will be selected if u follow wat i said..again i m saying pls concentrate on critical reasoning.. if all questions in it are right u r through..bye
WHAT ARE THE ADVANTAGE OF SYSTEM ENGINEER
what is the quantity of cement and sand in 1 sq.m (mortar ratio ) a, 1:4 b, 1:3 c, 1:6
HTML tag for bulleted list is--------------
Given a number (N), program to check whether its binary form has periodic or not
PLZ SOMEONE TELL ME WHICH TYPE OF QUESTIONS IS ASKED IN HLL(Hindustan latex ltd.)mangmt trainee entrance exam?
Q1. A. Discuss the various types of variables. B. How to control the file? Q2. A. How the image application? B. Write short notes on trees structures work. Q3. A. How to load and unload child forms. B. When should we use recursive programming Q4. A. Write short notes on “The ole control’s shortcut menu” B. How to test the AX stat class Q5. A. How to use advanced data-bound controls. B. Write notes on manipulating the recordset object Q6. A. What is script control? B. How to down load image properties. C. What is meant by building a recordset.
1.orders for a computer are summarized by the additional features and are requested as follows; Proportion of order No features 0.3 One feature only 0.5 More than one feature 0.2 find; 1. what is the probability that an order requests at least one feature? 2. what is the probability that an order does not request more than one feature?