C++ Interview Question and Answers
16. |
What is encapsulation? |
|
The binding of data and functions together into a single entity is referred to as encapsulation. |
|
|
17. |
What is data abstraction? |
|
Instruments allowing only selected access of components to objects and to members of other classes is called data abstraction. |
`
|
|
18. |
What are the two parts of a class specification? |
|
A class specification has two parts:-
Class declaration
-
Class function definitions
|
|
|
19. |
What is a class? |
|
- A class is a new way of creating and implementing a user defined data type.
-
Classes provide a method for packing together data of different types.
|
|
Ruthrapriya,says |
Feb 09, 2018 |
Class is the way to bind the data & it's associated functions together. |
|
20. |
How is polymorphism achieved? |
|
Polymorphism is achieved through function overloading and operator overloading. |
|
|