Skip to content

Overview

Member functions give you the ability to combine functionality and data within your structs/classes, with this giving rise to the term object to help us more easily talk about these entities within our programs.

Now that you have a basic understanding of member functions, let’s have a go at putting these together to create some simple entities with both functionality and data.

In this section we will build a simple account entity to model a bank account. In this, we will step through the mechanics of building this using a class. Following a more in-depth look at these features, we revisit our dynamic array from the memory deep dive chapter.