What are the OOPS concepts?
Answer Posted / ketan mehta
The followings are referred as the oops concepts:
Encapsulation:
wrapping up of data and member function
together into a single unit class.
Abstraction:
Showing essential feature without background
detail. Which leads to data security from unauthorized user.
Inheritance:
The property of one class inherited property
of other class. That means object of a child class need to
define only those properties that make it unique within its
class.
Polymorphism:
It is a feature that allows one entity to have
multiple forms.Polymorphism can be achived by Operator
overloading and Function overloading.
Is This Answer Correct ? | 4 Yes | 2 No |
Post New Answer View All Answers
i=20;k=0;
for(j=1;k-i;k+=j<10?4:3)
{
cout< What is difference between inheritance and polymorphism? What are the 3 principles of oop? What is coupling in oops? Can we define a class within the interface? class CTest
{
public:
void someMethod()
{
int nCount = 0;
cout << "This is some method --> " << nCount;
}
};
int main()
{
CTest *pctest;
pctest->someMethod();
return 0;
}
It will executes the someMethod() and displays the value
too. how is it possible with our creating memory for the
class . i think iam not creating object for the class.
Thanks in Advance...
Prakash What are different oops concepts? What is pure oop? Why do pointers exist? What does oop mean in snapchat? How do you answer polymorphism? Why multiple inheritance is not possible? to find out the minimum of two integer number of two different
classes using friend function How to call a non virtual function in the derived class by
using base class pointer What is encapsulation with example?