What is abstrac class?where is it use?

Answers were Sorted based on User's Feedback



What is abstrac class?where is it use?..

Answer / gp

Class which cannot be initiated is an abstract class.
You can make a class abstract by declaring a pure virtual method inside the class. For example:

class base
{
void func()=0;
};

void main()
{
base b;
}

Now you cannot instantiate base class.
The class which inherits this base class will also become abstract unless you define a body of the func() method in inherited class.

Is This Answer Correct ?    0 Yes 0 No

What is abstrac class?where is it use?..

Answer / vijaya lakshmi

abstrac class always said to algorithm. Bacause you
ara writing program before explain a program in algorithm

Is This Answer Correct ?    0 Yes 4 No

Post New Answer

More OOPS Interview Questions

//what is wrong with the programme?? #include<iostream.h> template <class first> class dd { first i; public: void set(); void print(); }; void dd< first>:: set() { cin>>i; } void dd< first>::print() { cout<<"\n"<<i; } void main() { dd <char>g; g.set(); g.print(); }

1 Answers  


2. Give the different notations for the class.\

0 Answers  


Can you explain polymorphism?

0 Answers  


What is the difference between static polymorphism and dynamic polymorphism?

0 Answers  


what is the size of an empty class

12 Answers   Wipro,


What is meant by oops concept?

0 Answers  


Can we override main method?

0 Answers  


what are the different types of qualifier in java?

0 Answers   TCS,


Write an operator overloading program to Overload ‘>’ operator so as to find greater among two instances of the class.

1 Answers  


if u write a class do u write Assignment operator and copy constructor

1 Answers   Siemens,


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.

0 Answers  


write a program to print * * * * * *

2 Answers  


Categories