What is the correct syntax for inheritance?




1) class aclass : public superclass


2) class aclass inherit superclass


3) class aclass <-superclass

Answer Posted / srikanth

class aclass inherit superclass

Is This Answer Correct ?    9 Yes 7 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

There are two base class B1,B2 and there is one class D which is derived from both classes, Explain the flow of calling constructors and destructors when an object of derived class is instantiated.

1424


What is encapsulation example?

527


Why is polymorphism needed?

567


Why do we use class in oops?

537


Write a program to compute for numeric grades for a course. The course records are in a file that will serve as the input file. The input file is in exactly the following format: Each line contains a student's first name, then one space, then ten quiz scores all on one line. The quiz scores are in whole number and are separated by one space. Your program will take it input from this file and sends it output to a second file. The data in the output file will be exactly the same as the data in the input file except that there will be one additional number (of type double) at the end of each line. This number will be the average of the student's ten quiz scores. Use at least one function that has file streams as all or some of its arguments.

2543






What is object in oops?

592


What is a class and object?

572


What is coupling in oops?

568


hi all..i want to know oops concepts clearly can any1 explain??

1661


What is abstraction in oop?

608


How do you explain polymorphism?

565


What is object and example?

576


Why do we use inheritance?

609


What are different types of JVM's? for example we use dalvik jvm for android then what about the remaining operating systems?

1630


Why is polymorphism important in oop?

613