Vectors
A vector is a collection of objects of a same type. For example you can have a vector of integers, a vector of strings, or even a vector of your own custom objects.
To use vectors, you need to include the <vector>
header:
#include <vector>
To create a vector, you need to put in the type it will hold. For example, to create a vector called grades
which holds integers:
std::vector<int> grades;
Your task is to create a vector called heights
which holds double
values on line number 7: