C++ Syntax Question: Download Basic C++ Syntax PDF

What is format for defining a structure?

Tweet Share WhatsApp

Answer:

The format for defining a structure is:

struct Tag {
Members
};
Where Tag is the name of the entire type of structure and Members are the variables within the struct. To actually create a single structure the syntax is
struct Tag name_of_single_structure;

Download Basic C++ Syntax PDF Read All 27 Basic C++ Syntax Questions
Previous QuestionNext Question
What is general format for a prototype?How to access a variable of the structure?