Answer Posted / arvind
Data & Functions in C++ are private by default. That means there is no previlige outside the class. The functions or objects defined outside the class can't access the data and functions.So by making data and functions private with in the class, its making the data hiding and function hiding. By default data is private and functions are public. So this is the concept of data hiding
Is This Answer Correct ? | 9 Yes | 2 No |
Post New Answer View All Answers
How is class defined?
Will I be able to get a picture in D drive to the c++ program? If so, help me out?
How to call a non virtual function in the derived class by using base class pointer
How to handle exception in c++, For example in a functions i am assigning memory to some variables and also in next instructions in am dividing one variable also. If this functions generates a error while allocating memory to those variable and also while dividing the variable if i divide by zero then catch block how it will identify that this error has cone from perticular instruction
String = "C++ is an object oriented programming language.An imp feature of oops is classes and objects".Write a pgm to count the repeated words from this scenario?
What does sksksk mean in text slang?
How is polymorphism achieved?
What is the main purpose of inheritance law?
What is cohesion in oop?
What is Difference Between Inheritance and creating object and getting data? means Class A extends B{ B.getMethod();} (OR) Class A{ b obj=new B(); obj.getMethod(); }
what is the drawback of classical methods in oops?
How do you achieve runtime polymorphism?
can inline function declare in private part of class?
Why is there no multiple inheritance?
What is polymorphism and why is it important?