What is structure in c++

What is structure in c++

What is structure in c++

What is Structure in C++?

Structure is a collection of variables of different data types under a single name.



Structure is an assortment of factors of various information types under a solitary name. It is like a class in that, the two holds a collection of information of various information types. For instance: You need to store some data about an individual: his/her name, citizenship number and pay.

Simple Code of C++ Structure

It is the example of structure in c++, you learn how structure works. Also we define functions in structure, yes it is possible like classes and objects in C++.

Functions define in Structure code in C++

> Also we apply concept of inheritance in structures, in next code we learn how to apply concept of inheritance in structure.

Apply Inheritance in structure code in C++

By default the permission is Public. So we can change the permission same like classes in OOP

Access specifiers in Structure C++

4 Responses to "What is structure in c++"

  1. Ali supereb🙃👍you done a very well work.
    I learn a lot .

    ReplyDelete
  2. Very well done👍 professor Ali. You make programming more easy for us thankyou very much, Keep it up.

    ReplyDelete

If you have any doubt or any problem, please let me know.