Difference between struct and class in terms of access modifier.
Answer / Rahul Jain
By default, members of a C++ class are private, while members of a struct are public. This means that the data members of a class must be explicitly declared as public, protected, or private, but the data members of a struct have the same access level as their containing scope unless explicitly modified.
| Is This Answer Correct ? | 0 Yes | 0 No |
How do you print a string on the printer?
Define macro.
What is the basic of c++?
What is the difference between function overloading and operator overloading?
What is the limitation of cin while taking input for character array?
Is it possible to write a c++ template to check for a function's existence?
How can you create a virtual copy constructor?
Which software is used to run c++ program?
How to create a pure virtual function?
What is an arraylist c++?
Are vectors faster than arrays?
Define linked lists with the help of an example.