Support

Support Options

Submit a Support Ticket

 

C++ Structures

In object oriented, as well as in procedural programming, data structures play an important role. These are used to hold large data blocks in an ordered way. C++ structures seem more less like classes. The only difference is that these cannot hold any method definitions or perform any function with the information they hold.

Example of a simple structure


struct triangle

{

double base;

double height;

}

  1. Programming

Comments on this entry

There are no comments at this time.

Post a comment

Please keep comments relevant to this entry.

Line breaks and paragraphs are automatically converted. URLs (starting with http://) or email addresses will automatically be linked.

nanoHUB.org, a resource for nanoscience and nanotechnology, is supported by the National Science Foundation and other funding agencies. Any opinions, findings, and conclusions or recommendations expressed in this material are those of the author(s) and do not necessarily reflect the views of the National Science Foundation.