what is single inheritance?

Answer Posted / jasbir singh

when a single class is being inherited by a class, it is
called single or simple inheritance.

example:

class a
{
public:
int x,y;
};
class b: public a //// example of simple inhieritence
{
public:
int z;
}

Is This Answer Correct ?    91 Yes 19 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Where You Can Use Interface in your Project

1506


Why do we use polymorphism in oops?

678


What causes polymorphism?

673


What is polymorphism used for?

656


What is the problem with multiple inheritance?

687






What is encapsulation process?

670


This program numbers the lines found in a text file. Write a program that reads text from a file and outputs each line preceded by a line number. Print the line number right-adjusted in a field of 3 spaces. Follow the line number with a colon, then one space, then the text of the line. You should get a character at a time and write code to ignore leading blanks on each line. You may assume that the lines are short enough to fit within a line on the screen. Otherwise, allow default printer or screen output behavior if the line is too long (i.e., wrap or truncate). A somewhat harder version determines the number of spaces needed in the field for the line numbers by counting lines before processing the lines of the file. This version of the program should insert a new line after the last complete word that will fit within a 72-character line.

1727


Write a program to sort the number with different sorts in one program ??

1996


They started with the brief introduction followed by few basic C++ questions on polumorphism, inheritance and then virtual functions. What is polymorphims? How you will access polymorphic functions in C? How virtual function mechanism works?

1490


What is and I oop mean?

721


What is the real time example of encapsulation?

686


What is abstraction in oops?

677


What are the 4 pillars of oop?

755


Can you inherit a private class?

736


What is the main purpose of inheritance law?

766