Structures in C++

The syntax for declaring structures:
struct Typename       // name of the structure
{
  type member_name;   // variable declaration
  type member_name;   // variable declaration
  . . .               // other variable declarations
};                    // don't forget semi-colon!
Notice that struct is a new keyword.

Next page

Back to Lesson 14 Index
Back to Outline