C++ 08 – Structs

A lot of the variables we use in our programs are related. For example, the two coordinates of a 2D vector, or a pointer pointing to an array and the size of said array. It would be useful if we could define types that consist of several variables grouped together.

In C++ and other languages, this can be achieved through the use of structs. In this lesson we will see how and why structs are used.
Continue reading “C++ 08 – Structs”

C++ L03 – Variables, types and operators

In order to be able to do something interesting and useful with C++, we have to take advantage of computer memory. The way we use computer memory is though variables.

On this post, I will show how you can define and use variables and apply operations on them.

Continue reading “C++ L03 – Variables, types and operators”